diff options
Diffstat (limited to 'rpmmodule/rpmmodule.c')
-rw-r--r-- | rpmmodule/rpmmodule.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/rpmmodule/rpmmodule.c b/rpmmodule/rpmmodule.c index f4e72aa95..c1b9d361c 100644 --- a/rpmmodule/rpmmodule.c +++ b/rpmmodule/rpmmodule.c @@ -306,8 +306,9 @@ static PyObject * rpmHeaderFromList(PyObject * self, PyObject * args) { } list = PyList_New(0); - + Py_BEGIN_ALLOW_THREADS header = headerRead(fd, HEADER_MAGIC_YES); + Py_END_ALLOW_THREADS while (header) { h = (hdrObject *) PyObject_NEW(PyObject, &hdrType); h->h = header; @@ -322,7 +323,9 @@ static PyObject * rpmHeaderFromList(PyObject * self, PyObject * args) { Py_DECREF(h); + Py_BEGIN_ALLOW_THREADS header = headerRead(fd, HEADER_MAGIC_YES); + Py_END_ALLOW_THREADS } fdClose(fd); |