Pablo Torres Navarrete <[email protected]> added the comment:
Wouldn't it be more pythonic to just try sys.stdin.fileno() and catch
the AtributeError too?
def _bootstrap(self):
....
try:
os.close(sys.stdin.fileno())
except AtributeError:
sys.stdin.close()
except (OSError, ValueError):
pass
----------
nosy: +ptn
_______________________________________
Python tracker <[email protected]>
<http://bugs.python.org/issue5313>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe:
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com