Revision: 12513
Author: [email protected]
Date: Fri Sep 14 06:19:42 2012
Log: Fix test failures on nosnap builder.
Review URL: https://chromiumcodereview.appspot.com/10915277
http://code.google.com/p/v8/source/detail?r=12513
Modified:
/branches/bleeding_edge/src/serialize.cc
/branches/bleeding_edge/src/snapshot-common.cc
=======================================
--- /branches/bleeding_edge/src/serialize.cc Fri Sep 14 04:16:56 2012
+++ /branches/bleeding_edge/src/serialize.cc Fri Sep 14 06:19:42 2012
@@ -1618,7 +1618,7 @@
bool SnapshotByteSource::AtEOF() {
- if (0u + length_ - position_ > sizeof(uint32_t)) return false;
+ if (0u + length_ - position_ > 2 * sizeof(uint32_t)) return false;
for (int x = position_; x < length_; x++) {
if (data_[x] != SerializerDeserializer::nop()) return false;
}
=======================================
--- /branches/bleeding_edge/src/snapshot-common.cc Fri Sep 14 04:16:56 2012
+++ /branches/bleeding_edge/src/snapshot-common.cc Fri Sep 14 06:19:42 2012
@@ -86,10 +86,13 @@
int len;
byte* str = ReadBytes(snapshot_file, &len);
if (!str) return false;
- SnapshotByteSource source(str, len);
- Deserializer deserializer(&source);
- ReserveSpaceForSnapshot(&deserializer, snapshot_file);
- bool success = V8::Initialize(&deserializer);
+ bool success;
+ {
+ SnapshotByteSource source(str, len);
+ Deserializer deserializer(&source);
+ ReserveSpaceForSnapshot(&deserializer, snapshot_file);
+ success = V8::Initialize(&deserializer);
+ }
DeleteArray(str);
return success;
} else if (size_ > 0) {
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev