[Lldb-commits] [PATCH] D18057: Fixed an issue where python would always use stdin, stdout and stderr
Greg Clayton via lldb-commits
lldb-commits at lists.llvm.org
Thu Mar 10 11:37:50 PST 2016
clayborg created this revision.
clayborg added a reviewer: zturner.
clayborg added a subscriber: lldb-commits.
After the Python 3 fixes the interactive python interpreter stopped working in Xcode. The issue was the python interpreter tried to adopt the top IOHandler file handles, but it failed due to lldb_private::File objects failing to copy themselves into another lldb_private::File because they contained "FILE *" file stream pointer, not just an integer file descriptor, and File::Duplicate() didn't handle duplicating "FILE *". But we really don't want files duplicating themselves each time we run a python expression, we just want to use the files.
The fix involves removing File::Duplicate() since we shouldn't be using this and duplicating files. It also removes File's assignment operator and copy constructor. It then fixes the python interpreter to correctly adopt the file handles from the top IOHandler.
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 6803 bytes
Desc: not available
More information about the lldb-commits