Modifies write() so that NULs are allowed within a string.

This is required by the mandelbrot test in the language shootout.

Patch by abdulla <abdulla.kamar@gmail.com>.


git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@2821 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent d03c277f
......@@ -159,8 +159,7 @@ Handle<Value> Shell::Write(const Arguments& args) {
printf(" ");
}
v8::String::Utf8Value str(args[i]);
const char* cstr = ToCString(str);
printf("%s", cstr);
fwrite(*str, sizeof(*str), str.length(), stdout);
}
return Undefined();
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment