diff -r f7eda8165e6f Objects/bytesobject.c --- a/Objects/bytesobject.c Sat Jan 26 12:14:02 2013 +0200 +++ b/Objects/bytesobject.c Sat Jan 26 12:23:20 2013 +0200 @@ -29,8 +29,8 @@ Py_ssize_t null_strings, one_strings; #endif -static PyBytesObject *characters[UCHAR_MAX + 1]; -static PyBytesObject *nullstring; +static PyBytesObject *characters[UCHAR_MAX + 1] = {NULL}; +static PyBytesObject *nullstring = NULL; /* PyBytesObject_SIZE gives the basic size of a string; any memory allocation for a string of length n should request PyBytesObject_SIZE + n bytes. @@ -3008,12 +3008,9 @@ PyBytes_Fini(void) { int i; - for (i = 0; i < UCHAR_MAX + 1; i++) { - Py_XDECREF(characters[i]); - characters[i] = NULL; - } - Py_XDECREF(nullstring); - nullstring = NULL; + for (i = 0; i < UCHAR_MAX + 1; i++) + Py_CLEAR(characters[i]); + Py_CLEAR(nullstring); } /*********************** Bytes Iterator ****************************/