Index: src/snapshot-common.cc |
=================================================================== |
--- src/snapshot-common.cc (revision 12511) |
+++ src/snapshot-common.cc (working copy) |
@@ -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) { |