• Raymond Hettinger's avatar
    Checkin Tim's fix to an error discussed on python-dev. · aa241e01
    Raymond Hettinger yazdı
    Also, add a testcase.
    
    Formerly, the list_extend() code used several local variables to remember
    its state across iterations.  Since an iteration could call arbitrary
    Python code, it was possible for the list state to be changed.  The new
    code uses dynamic structure references instead of C locals.  So, they
    are always up-to-date.
    
    After list_resize() is called, its size has been updated but the new
    cells are filled with NULLs.  These needed to be filled before arbitrary
    iteration code was called; otherwise, that code could attempt to modify
    a list that was in a semi-invalid state.  The solution was to change
    the ob->size field back to a value reflecting the actual number of valid
    cells.
    aa241e01
Adı
Son kayıt (commit)
Son güncelleme
Demo Loading commit data...
Doc Loading commit data...
Grammar Loading commit data...
Include Loading commit data...
Lib Loading commit data...
Mac Loading commit data...
Misc Loading commit data...
Modules Loading commit data...
Objects Loading commit data...
PC Loading commit data...
PCbuild Loading commit data...
Parser Loading commit data...
Python Loading commit data...
RISCOS Loading commit data...
Tools Loading commit data...
.cvsignore Loading commit data...
.hgtags Loading commit data...
LICENSE Loading commit data...
Makefile.pre.in Loading commit data...
README Loading commit data...
aclocal.m4 Loading commit data...
configure Loading commit data...
configure.in Loading commit data...
install-sh Loading commit data...
pyconfig.h.in Loading commit data...
setup.py Loading commit data...