We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Tried on current main.
./python -m test -R 3:3 test_doctest Running Debug|x64 interpreter... 0:00:00 Run tests sequentially 0:00:00 [1/1] test_doctest beginning 6 repetitions 123456 <frozen importlib._bootstrap>:824: ImportWarning: TestImporter.exec_module() not found; falling back to load_module() .<frozen importlib._bootstrap>:824: ImportWarning: TestImporter.exec_module() not found; falling back to load_module() .<frozen importlib._bootstrap>:824: ImportWarning: TestImporter.exec_module() not found; falling back to load_module() .<frozen importlib._bootstrap>:824: ImportWarning: TestImporter.exec_module() not found; falling back to load_module() .<frozen importlib._bootstrap>:824: ImportWarning: TestImporter.exec_module() not found; falling back to load_module() .<frozen importlib._bootstrap>:824: ImportWarning: TestImporter.exec_module() not found; falling back to load_module() . test_doctest leaked [34, 34, 34] memory blocks, sum=102 test_doctest failed (reference leak) in 34.8 sec == Tests result: FAILURE == 1 test failed: test_doctest Total duration: 34.9 sec Tests result: FAILURE
The text was updated successfully, but these errors were encountered:
Bisected to #106411 cc @methane
Sorry, something went wrong.
This fixes the problem.
diff --git a/Python/compile.c b/Python/compile.c index b80f7c01bcd..6a144f30164 100644 --- a/Python/compile.c +++ b/Python/compile.c @@ -8060,7 +8060,9 @@ _PyCompile_CleanDoc(PyObject *doc) } Py_DECREF(doc); - return PyUnicode_FromStringAndSize(buff, w - buff); + PyObject* res = PyUnicode_FromStringAndSize(buff, w - buff); + PyMem_Free(buff); + return res; }
thanks
gh-106843: fix memleak in _PyCompile_CleanDoc (#106846)
ece3b9d
No branches or pull requests
Tried on current main.
Linked PRs
The text was updated successfully, but these errors were encountered: