X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~mdw/git/mLib-python/blobdiff_plain/b3c87d862e8f44754113ee9bf374e9fcfbc9e7ac..55b42c189e6a40e66b7beef6056fd8a484ee85f5:/ident.pyx diff --git a/ident.pyx b/ident.pyx index e7c05d2..1cc9e9e 100644 --- a/ident.pyx +++ b/ident.pyx @@ -1,29 +1,27 @@ -# -*-pyrex-*- -# -# $Id$ -# -# Ident client -# -# (c) 2005 Straylight/Edgeware -# +### -*-pyrex-*- +### +### Ident client +### +### (c) 2005 Straylight/Edgeware +### -#----- Licensing notice ----------------------------------------------------- -# -# This file is part of the Python interface to mLib. -# -# mLib/Python is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2 of the License, or -# (at your option) any later version. -# -# mLib/Python is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with mLib/Python; if not, write to the Free Software Foundation, -# Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +###----- Licensing notice --------------------------------------------------- +### +### This file is part of the Python interface to mLib. +### +### mLib/Python is free software; you can redistribute it and/or modify +### it under the terms of the GNU General Public License as published by +### the Free Software Foundation; either version 2 of the License, or +### (at your option) any later version. +### +### mLib/Python is distributed in the hope that it will be useful, +### but WITHOUT ANY WARRANTY; without even the implied warranty of +### MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +### GNU General Public License for more details. +### +### You should have received a copy of the GNU General Public License +### along with mLib/Python; if not, write to the Free Software Foundation, +### Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. import socket @@ -52,7 +50,7 @@ cdef class SelIdentify: cdef _error cdef _failed cdef _bogus - def __new__(me, sk, + def __cinit__(me, sk, userproc = None, bogusproc = None, badproc = None, errorproc = None, failedproc = None, *hunoz, **hukairz): @@ -157,7 +155,7 @@ cdef class SelIdentify: def bogus(me): return _maybecall(me._bogus, ()) -cdef void _identfunc2(ident_reply *i, void *arg): +cdef void _identfunc(ident_reply *i, void *arg): cdef SelIdentify id id = arg id._dead() @@ -167,9 +165,5 @@ cdef void _identfunc2(ident_reply *i, void *arg): id.error(i.u.error) elif i.type == IDENT_USERID: id.user(i.u.userid.os, i.u.userid.user) -cdef void _identfunc(ident_reply *i, void *arg): - PyEval_AcquireLock() - _identfunc2(i, arg) - PyEval_ReleaseLock() -#----- That's all, folks ---------------------------------------------------- +###----- That's all, folks --------------------------------------------------