Rpm's allocators dont return on OOM, remove unnecessary check
authorPanu Matilainen <pmatilai@redhat.com>
Wed, 23 Sep 2009 05:41:03 +0000 (08:41 +0300)
committerPanu Matilainen <pmatilai@redhat.com>
Wed, 23 Sep 2009 05:41:03 +0000 (08:41 +0300)
python/header-py.c

index 765331f..e8b7bd9 100644 (file)
@@ -537,11 +537,7 @@ PyObject * hdrLoad(PyObject * self, PyObject * args, PyObject * kwds)
     /* copy is needed to avoid surprises from data swab in headerLoad(). */
     h = headerCopyLoad(obj);
     if (!h) {
-       if (errno == ENOMEM) {
-           PyErr_SetString(pyrpmError, "out of memory");
-       } else {
-           PyErr_SetString(pyrpmError, "bad header");
-       }
+       PyErr_SetString(pyrpmError, "bad header");
        return NULL;
     }
     headerConvert(h, HEADERCONV_RETROFIT_V3);