mirror of
https://github.com/erkin/ponysay.git
synced 2024-11-23 04:47:59 +01:00
m
This commit is contained in:
parent
fcc9b8edcd
commit
13452afe3f
1 changed files with 2 additions and 1 deletions
|
@ -65,9 +65,10 @@ fd3 = None
|
||||||
'''
|
'''
|
||||||
def printinfo(text = '', end = '\n'):
|
def printinfo(text = '', end = '\n'):
|
||||||
global fd3
|
global fd3
|
||||||
if os.path.exists('/proc/self/fd/3'):
|
if os.path.exists('/proc/self/fd/3') and os.path.isfile('/proc/self/fd/3'):
|
||||||
if fd3 is None:
|
if fd3 is None:
|
||||||
fd3 = os.fdopen(3, 'w')
|
fd3 = os.fdopen(3, 'w')
|
||||||
|
if fd3 is not None:
|
||||||
fd3.write(str(text) + end)
|
fd3.write(str(text) + end)
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue