Mercurial > cpython-lru_cache-weakref
comparison Python/pythonrun.c @ 48847:b1682c693b9a legacy-trunk
Fix:
* crashes on memory allocation failure found with failmalloc
* memory leaks found with valgrind
* compiler warnings in opt mode which would lead to invalid memory reads
* problem using wrong name in decimal module reported by pychecker
Update the valgrind suppressions file with new leaks that are small/one-time
leaks we don't care about (ie, they are too hard to fix).
TBR=barry
TESTED=./python -E -tt ./Lib/test/regrtest.py -uall (both debug and opt modes)
in opt mode:
valgrind -q --leak-check=yes --suppressions=Misc/valgrind-python.supp \
./python -E -tt ./Lib/test/regrtest.py -uall,-bsddb,-compiler \
-x test_logging test_ssl test_multiprocessing
valgrind -q --leak-check=yes --suppressions=Misc/valgrind-python.supp \
./python -E -tt ./Lib/test/regrtest.py test_multiprocessing
for i in `seq 1 4000` ; do
LD_PRELOAD=~/local/lib/libfailmalloc.so FAILMALLOC_INTERVAL=$i \
./python -c pass
done
At least some of these fixes should probably be backported to 2.5.
| author | Neal Norwitz <nnorwitz@gmail.com> |
|---|---|
| date | Sun, 24 Aug 2008 05:04:52 +0000 |
| parents | 7ad6e4cd7713 |
| children | 6cac2e3077a3 |
comparison
equal
deleted
inserted
replaced
| 48845:e14552b7317b | 48847:b1682c693b9a |
|---|---|
| 130 { | 130 { |
| 131 PyInterpreterState *interp; | 131 PyInterpreterState *interp; |
| 132 PyThreadState *tstate; | 132 PyThreadState *tstate; |
| 133 PyObject *bimod, *sysmod; | 133 PyObject *bimod, *sysmod; |
| 134 char *p; | 134 char *p; |
| 135 char *icodeset; /* On Windows, input codeset may theoretically | 135 char *icodeset = NULL; /* On Windows, input codeset may theoretically |
| 136 differ from output codeset. */ | 136 differ from output codeset. */ |
| 137 char *codeset = NULL; | 137 char *codeset = NULL; |
| 138 char *errors = NULL; | 138 char *errors = NULL; |
| 139 int free_codeset = 0; | 139 int free_codeset = 0; |
| 140 int overridden = 0; | 140 int overridden = 0; |
| 141 PyObject *sys_stream, *sys_isatty; | 141 PyObject *sys_stream, *sys_isatty; |
