is called with the (unsupported and unexported in this version) flag DB_ARCH_REMOVE.
also fix a log_list memory leak on error return in the event that python can't create
a new list object.
{
int flags=0;
int err;
- char **log_list_start, **log_list;
+ char **log_list = NULL;
PyObject* list;
PyObject* item = NULL;
list = PyList_New(0);
if (list == NULL) {
+ if (log_list)
+ free(log_list);
PyErr_SetString(PyExc_MemoryError, "PyList_New failed");
return NULL;
}
if (log_list) {
+ char **log_list_start;
for (log_list_start = log_list; *log_list != NULL; ++log_list) {
item = PyString_FromString (*log_list);
if (item == NULL) {