Revision: 4168
Author: [email protected]
Date: Wed Mar 17 07:42:01 2010
Log: Properly release zero-length Vectors.

Review URL: http://codereview.chromium.org/987004
http://code.google.com/p/v8/source/detail?r=4168

Modified:
 /branches/bleeding_edge/src/utils.h

=======================================
--- /branches/bleeding_edge/src/utils.h Fri Mar 12 02:20:01 2010
+++ /branches/bleeding_edge/src/utils.h Wed Mar 17 07:42:01 2010
@@ -341,8 +341,8 @@
   // Releases the array underlying this vector. Once disposed the
   // vector is empty.
   void Dispose() {
-    if (is_empty()) return;
     DeleteArray(start_);
+    if (is_empty()) return;
     start_ = NULL;
     length_ = 0;
   }

--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev

Reply via email to