summaryrefslogtreecommitdiffstats
path: root/Doc
diff options
context:
space:
mode:
authorFred Drake <fdrake@acm.org>2001-05-10 15:57:17 (GMT)
committerFred Drake <fdrake@acm.org>2001-05-10 15:57:17 (GMT)
commit791c351b3d9b311da1ab71a53619d3947a7fce46 (patch)
treeee55305104f781d8966158300e649b3d0e45dc67 /Doc
parent1d531997a64db69496beb0f69143800c6b8a98ca (diff)
downloadcpython-791c351b3d9b311da1ab71a53619d3947a7fce46.zip
cpython-791c351b3d9b311da1ab71a53619d3947a7fce46.tar.gz
cpython-791c351b3d9b311da1ab71a53619d3947a7fce46.tar.bz2
Update example to no longer use the FCNTL module.
Diffstat (limited to 'Doc')
-rw-r--r--Doc/lib/libsignal.tex4
1 files changed, 2 insertions, 2 deletions
diff --git a/Doc/lib/libsignal.tex b/Doc/lib/libsignal.tex
index 11f0737..fe9b180 100644
--- a/Doc/lib/libsignal.tex
+++ b/Doc/lib/libsignal.tex
@@ -155,7 +155,7 @@ the file; if the operation takes too long, the alarm signal will be
sent, and the handler raises an exception.
\begin{verbatim}
-import signal, os, FCNTL
+import signal, os
def handler(signum, frame):
print 'Signal handler called with signal', signum
@@ -166,7 +166,7 @@ signal.signal(signal.SIGALRM, handler)
signal.alarm(5)
# This open() may hang indefinitely
-fd = os.open('/dev/ttyS0', FCNTL.O_RDWR)
+fd = os.open('/dev/ttyS0', os.O_RDWR)
signal.alarm(0) # Disable the alarm
\end{verbatim}