Index: src/d8.cc |
diff --git a/src/d8.cc b/src/d8.cc |
index 5361869a7e2a6ee13de740f666fafa5f6c00db1d..cbf2dafc2dbab922ef112cc144d0889c0bbb0320 100644 |
--- a/src/d8.cc |
+++ b/src/d8.cc |
@@ -1485,7 +1485,7 @@ Handle<String> Shell::ReadFile(Isolate* isolate, const char* name) { |
int size = 0; |
char* chars = ReadChars(isolate, name, &size); |
if (chars == NULL) return Handle<String>(); |
- Handle<String> result = String::New(chars); |
+ Handle<String> result = String::New(chars, size); |
delete[] chars; |
return result; |
} |