* ceval.c: ifdef out the last argument passing compat hack.

* Fixed memory leaks in socket, select and sv modules: mkvalue("O", v)
  does INCREF(v) so if v is brand new it should be XDECREF'd
This commit is contained in:
Guido van Rossum 1993-02-05 09:46:15 +00:00
parent 995c33a2bb
commit 6f5afc9a73
4 changed files with 37 additions and 29 deletions

View file

@ -112,6 +112,7 @@ select_select(self, args)
{
object *fd2obj[FD_SETSIZE];
object *ifdlist, *ofdlist, *efdlist;
object *ret;
fd_set ifdset, ofdset, efdset;
double timeout;
struct timeval tv, *tvp;
@ -168,8 +169,11 @@ select_select(self, args)
ifdlist = set2list(&ifdset, imax, fd2obj);
ofdlist = set2list(&ofdset, omax, fd2obj);
efdlist = set2list(&efdset, emax, fd2obj);
return mkvalue("OOO", ifdlist, ofdlist, efdlist);
ret = mkvalue("OOO", ifdlist, ofdlist, efdlist);
XDECREF(ifdlist);
XDECREF(ofdlist);
XDECREF(efdlist);
return ret;
}