chiark / gitweb /
ident.pyx, defs.pxi: Use Pyrex `typecheck' for type checking.
[mLib-python] / ident.pyx
index 90d8f0f64b13849a976dee96b2076dafdda1179b..7ea6b454d10c749da8c24059cae6bed0f0b5783c 100644 (file)
--- a/ident.pyx
+++ b/ident.pyx
@@ -57,7 +57,7 @@ cdef class SelIdentify:
     cdef sockaddr_in s_in, s_out
     cdef socklen_t sz_in, sz_out
     cdef int fd
-    if PyObject_TypeCheck(sk, socket.SocketType):
+    if typecheck(sk, socket.SocketType):
       fd = sk.fileno()
       sz_in = PSIZEOF(&s_in)
       sz_out = PSIZEOF(&s_out)