Author: Gabriel <[email protected]>
Branch:
Changeset: r58210:731e68c58945
Date: 2012-10-12 19:07 +0200
http://bitbucket.org/pypy/pypy/changeset/731e68c58945/
Log: Don't forget the return value, so that ioctl works on int args.
diff --git a/pypy/module/fcntl/interp_fcntl.py
b/pypy/module/fcntl/interp_fcntl.py
--- a/pypy/module/fcntl/interp_fcntl.py
+++ b/pypy/module/fcntl/interp_fcntl.py
@@ -250,6 +250,9 @@
else:
intarg = rffi.cast(rffi.INT, intarg) # C long => C int
rv = ioctl_int(fd, op, intarg)
+ if rv < 0:
+ raise _get_error(space, "ioctl")
+ return space.wrap(rv)
try:
arg = space.bufferstr_w(w_arg)
_______________________________________________
pypy-commit mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-commit