mirror of
https://github.com/python/cpython.git
synced 2026-05-06 20:51:17 -04:00
gh-132983: Fix refleak in zstd dictionary functions (gh-134459)
This commit is contained in:
@@ -251,7 +251,7 @@ _zstd_train_dict_impl(PyObject *module, PyBytesObject *samples_bytes,
|
||||
&chunk_sizes);
|
||||
if (chunks_number < 0)
|
||||
{
|
||||
return NULL;
|
||||
goto error;
|
||||
}
|
||||
|
||||
/* Allocate dict buffer */
|
||||
@@ -333,7 +333,7 @@ _zstd_finalize_dict_impl(PyObject *module, PyBytesObject *custom_dict_bytes,
|
||||
&chunk_sizes);
|
||||
if (chunks_number < 0)
|
||||
{
|
||||
return NULL;
|
||||
goto error;
|
||||
}
|
||||
|
||||
/* Allocate dict buffer */
|
||||
|
||||
Reference in New Issue
Block a user