Cleanup: replace StringIO seek() & read() with a call to getvalue()

This commit is contained in:
2022-12-18 14:18:01 +11:00
parent 8709a51fa9
commit 5a761a47e1
3 changed files with 4 additions and 10 deletions

View File

@@ -156,11 +156,8 @@ def execute(context, is_interactive):
if _BPY_MAIN_OWN:
sys.modules["__main__"] = main_mod_back
stdout.seek(0)
stderr.seek(0)
output = stdout.read()
output_err = stderr.read()
output = stdout.getvalue()
output_err = stderr.getvalue()
# cleanup
sys.last_traceback = None