Sfaely flush thread on buffer

This commit is contained in:
Anthony Scopatz 2016-10-13 21:26:49 -04:00
parent 2428e445fc
commit 74bcae6e7c
2 changed files with 2 additions and 1 deletions

View file

@ -12,5 +12,6 @@
the function ProcProxies were not being waited upon.
* Fixed issue with callablable aliases that happen to call sys.exit() or
raise SystemExit taking out the whole xonsh process.
* Safely flushes file handles on threaded buffers.
**Security:** None

View file

@ -795,7 +795,7 @@ class FileThreadDispatcher:
def flush(self):
"""Flushes the file descriptor for the current thread."""
return self.handle.flush()
return safe_flush(self.handle)
def isatty(self):
"""Returns if the file descriptor for the current thread is a tty."""