Reviewers: Lasse Reichstein,

Description:
Fix raw pointer misuse in StringReplaceRegExpWithEmptyString.

Please review this at http://codereview.chromium.org/6905035/

SVN Base: https://v8.googlecode.com/svn/branches/bleeding_edge

Affected files:
  M src/runtime.cc


Index: src/runtime.cc
diff --git a/src/runtime.cc b/src/runtime.cc
index d8aaf718097616ae83cc35fa1e9d56121774ea48..ff0503718b5c93262a33eda9f7ab8d24a6d379a4 100644
--- a/src/runtime.cc
+++ b/src/runtime.cc
@@ -2713,7 +2713,7 @@ MUST_USE_RESULT static MaybeObject* StringReplaceRegExpWithEmptyString(
     end = RegExpImpl::GetCapture(match_info_array, 1);
   }

-  int length = subject->length();
+  int length = subject_handle->length();
   int new_length = length - (end - start);
   if (new_length == 0) {
     return isolate->heap()->empty_string();


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

Reply via email to