do not create fifo if not there

master
Florian Streibelt 13 years ago
parent 7bcc8f0c18
commit 5c15a18110

@ -35,16 +35,11 @@ display_fifo = None
def print_display(s):
global display_fifo
"""
Comment out this return for now if you dont
want to use the display.
return
"""
if not display_fifo:
try:
display_fifo = open('/tmp/display', 'w')
#display_fifo = open('/tmp/display', 'w')
fd = os.open( "/tmp/display", os.O_WRONLY)
display_fifo = os.fdopen(fd,"w")
except IOError:
display_fifo = None
return

Loading…
Cancel
Save