[pypy-svn] r46841 - pypy/dist/pypy/rlib

arigo at codespeak.net arigo at codespeak.net
Sun Sep 23 17:53:17 CEST 2007


Author: arigo
Date: Sun Sep 23 17:53:17 2007
New Revision: 46841

Modified:
   pypy/dist/pypy/rlib/rpoll.py
Log:
Translation fixes.


Modified: pypy/dist/pypy/rlib/rpoll.py
==============================================================================
--- pypy/dist/pypy/rlib/rpoll.py	(original)
+++ pypy/dist/pypy/rlib/rpoll.py	Sun Sep 23 17:53:17 2007
@@ -56,8 +56,10 @@
             retval = []
             for i in range(numfd):
                 pollfd = pollfds[i]
-                if pollfd.c_revents:
-                    retval.append((pollfd.c_fd, pollfd.c_revents))
+                fd      = rffi.cast(lltype.Signed, pollfd.c_fd)
+                revents = rffi.cast(lltype.Signed, pollfd.c_revents)
+                if revents:
+                    retval.append((fd, revents))
         finally:
             lltype.free(pollfds, flavor='raw')
         return retval



More information about the Pypy-commit mailing list