Commit cdb78e8f authored by Guido van Rossum's avatar Guido van Rossum

Call printobject instead of fwrite to print strings.

parent dc0f9552
......@@ -442,8 +442,8 @@ eval_code(co, globals, locals, arg)
if (is_stringobject(v)) {
char *s = getstringvalue(v);
int len = getstringsize(v);
fwrite(s, 1, len, fp);
if (len > 0 && s[len-1] == '\n')
err = printobject(v, fp, PRINT_RAW);
if (err == 0 && len > 0 && s[len-1] == '\n')
softspace(sysget("stdout"), 0);
}
else {
......
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