Revision: 9755
Author: [email protected]
Date: Mon Oct 24 05:39:29 2011
Log: Fix crash in partial snapshot test when running with no boot
snapshot.
Review URL: http://codereview.chromium.org/8381003
http://code.google.com/p/v8/source/detail?r=9755
Modified:
/branches/bleeding_edge/src/serialize.cc
=======================================
--- /branches/bleeding_edge/src/serialize.cc Fri Oct 21 08:20:53 2011
+++ /branches/bleeding_edge/src/serialize.cc Mon Oct 24 05:39:29 2011
@@ -757,7 +757,7 @@
void Deserializer::ReadChunk(Object** current,
Object** limit,
int source_space,
- Address address) {
+ Address current_object_address) {
Isolate* const isolate = isolate_;
while (current < limit) {
int data = source_->Get();
@@ -845,9 +845,11 @@
*current =
new_object; \
} \
} \
- if (emit_write_barrier)
{ \
- isolate->heap()->RecordWrite(address,
static_cast<int>( \
- reinterpret_cast<Address>(current) -
address)); \
+ if (emit_write_barrier && current_object_address != NULL)
{ \
+ Address current_address =
reinterpret_cast<Address>(current); \
+
isolate->heap()->RecordWrite( \
+
current_object_address, \
+ static_cast<int>(current_address -
current_object_address)); \
} \
if (!current_was_incremented)
{ \
current++; /* Increment current if it wasn't done above.
*/ \
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev