flush was closing

This commit is contained in:
Anthony Scopatz 2016-10-01 12:48:12 -04:00
parent 8b5c91bfd8
commit 7be281375a

View file

@ -259,7 +259,7 @@ def safe_flush(handle):
"""Attempts to safely flush a file handle, returns success bool."""
status = True
try:
handle.close()
handle.flush()
except OSError:
status = False
return status