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

Unified Diff: src/serialize.cc

Issue 390353002: Fix assertion failure. Use Vector instead of List in code deserializer. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: move dispose to the destructor of Deserializer Created 6 years, 5 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 | « src/serialize.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/serialize.cc
diff --git a/src/serialize.cc b/src/serialize.cc
index 5e75ee569d373acebcfa466f8dc669fa4ccba508..eedbab4cd6e0f50053288dfa73d2f69056f9a2da 100644
--- a/src/serialize.cc
+++ b/src/serialize.cc
@@ -811,6 +811,7 @@ Deserializer::~Deserializer() {
delete external_reference_decoder_;
external_reference_decoder_ = NULL;
}
+ if (attached_objects_) attached_objects_->Dispose();
}
@@ -2003,8 +2004,8 @@ Handle<SharedFunctionInfo> CodeSerializer::Deserialize(Isolate* isolate,
DisallowHeapAllocation no_gc;
// Prepare and register list of attached objects.
- List<Object*> attached_objects(1);
- attached_objects.Set(kSourceObjectIndex, *source);
+ Vector<Object*> attached_objects = Vector<Object*>::New(1);
+ attached_objects[kSourceObjectIndex] = *source;
deserializer.SetAttachedObjects(&attached_objects);
Object* root;
« no previous file with comments | « src/serialize.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698