Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(39)

Unified Diff: src/api.cc

Issue 7105016: Ensure strings are never externalized as a side-effect of doing a GC. (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 9 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | src/heap.h » ('j') | src/heap.h » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/api.cc
===================================================================
--- src/api.cc (revision 8139)
+++ src/api.cc (working copy)
@@ -4264,6 +4264,9 @@
if (isolate->string_tracker()->IsFreshUnusedString(obj)) {
return false;
}
+ if (isolate->heap()->gc_post_process_count() > 0) {
+ return false;
+ }
bool result = obj->MakeExternal(resource);
if (result && !obj->IsSymbol()) {
isolate->heap()->external_string_table()->AddString(*obj);
@@ -4296,6 +4299,9 @@
if (isolate->string_tracker()->IsFreshUnusedString(obj)) {
return false;
}
+ if (isolate->heap()->gc_post_process_count() > 0) {
+ return false;
+ }
bool result = obj->MakeExternal(resource);
if (result && !obj->IsSymbol()) {
isolate->heap()->external_string_table()->AddString(*obj);
« no previous file with comments | « no previous file | src/heap.h » ('j') | src/heap.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698