summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPanu Matilainen <pmatilai@redhat.com>2013-12-20 15:11:56 +0200
committerPanu Matilainen <pmatilai@redhat.com>2014-01-17 13:20:13 +0200
commit94bf577877a431bda0f57f92885bd7f7e815dc53 (patch)
treed9fffa2a47c3c95b31fcf18b897b5dfad593b2d8
parent270b484ba1da7bad789d50b71f4ccc6ab373dea5 (diff)
downloadrpm-94bf577877a431bda0f57f92885bd7f7e815dc53.tar.gz
Use correct conversion format for python strpool id's
- We need an unsigned int, not unsigned long. Funnily enough "k" worked with gcc -O0 and -O1 but blows up when built with -O2. (cherry picked from commit 209cd9f04a83140f63391f40f5ccb85ac8d5836d)
-rw-r--r--python/rpmstrpool-py.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/python/rpmstrpool-py.c b/python/rpmstrpool-py.c
index d5a6c388b..356bd1de5 100644
--- a/python/rpmstrpool-py.c
+++ b/python/rpmstrpool-py.c
@@ -40,7 +40,7 @@ static PyObject *strpool_id2str(rpmstrPoolObject *s, PyObject *item)
PyObject *ret = NULL;
rpmsid id = 0;
- if (PyArg_Parse(item, "k", &id)) {
+ if (PyArg_Parse(item, "I", &id)) {
const char *str = rpmstrPoolStr(s->pool, id);
if (str)