Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions src/_path_wrapper.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -727,6 +727,7 @@ static PyObject *Py_convert_to_string(PyObject *self, PyObject *args, PyObject *
return NULL;
}
codes[i] = PyBytes_AsString(item);
Py_DECREF(item);
if (codes[i] == NULL) {
return NULL;
}
Expand Down
1 change: 1 addition & 0 deletions src/py_adaptors.h
Original file line number Diff line number Diff line change
Expand Up @@ -240,6 +240,7 @@ class PathGenerator
throw py::exception();
}
if (!convert_path(item, &path)) {
Py_DECREF(item);
throw py::exception();
}
Py_DECREF(item);
Expand Down