fcntl O_NDELAY constant not found in python 2.3 on linux
Andrew MacIntyre
andymac at bullseye.apana.org.au
Sat Jan 24 17:37:18 EST 2004
On Fri, 23 Jan 2004, Ryan Grow wrote:
> import os, fcntl, FCNTL
>
> file = open("/tmp/testfd.txt", 'w')
> fd = file.fileno()
> fl = fcntl.fcntl(fd, FCNTL.F_GETFL)
fl = fcntl.fcntl(fd, fcntl.F_GETFL)
^^^^^
> fcntl.fcntl(fd, FCNTL.F_SETFL, fl | FCNTL.O_NDELAY)
fcntl.fcntl(fd, fcntl.F_SETFL, fl | os.O_NDELAY)
^^^^^ ^^
> print "Made it!"
All the symbols in FCNTL are available either in fcntl or os.
--
Andrew I MacIntyre "These thoughts are mine alone..."
E-mail: andymac at bullseye.apana.org.au (pref) | Snail: PO Box 370
andymac at pcug.org.au (alt) | Belconnen ACT 2616
Web: http://www.andymac.org/ | Australia
More information about the Python-list
mailing list