Reviewers: Yang, danno,

Message:
please review , thanks!

Description:
fix StrDup memory leak in CcTest

BUG=

Please review this at https://codereview.chromium.org/421153002/

SVN Base: https://github.com/v8/v8.git@master

Affected files (+1, -0 lines):
  M test/cctest/cctest.h


Index: test/cctest/cctest.h
diff --git a/test/cctest/cctest.h b/test/cctest/cctest.h
index fc6ec398fd03a1464a9cb1e618b67612a17b72ff..00905978ece645283c50a0215b8d5a37a40a9367 100644
--- a/test/cctest/cctest.h
+++ b/test/cctest/cctest.h
@@ -98,6 +98,7 @@ class CcTest {
   typedef void (TestFunction)();
   CcTest(TestFunction* callback, const char* file, const char* name,
          const char* dependency, bool enabled, bool initialize);
+  ~CcTest() { i::DeleteArray(file_); }
   void Run();
   static CcTest* last() { return last_; }
   CcTest* prev() { return prev_; }


--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
--- You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to