summaryrefslogtreecommitdiffstats
path: root/rpminfo.c
diff options
context:
space:
mode:
Diffstat (limited to 'rpminfo.c')
-rw-r--r--rpminfo.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/rpminfo.c b/rpminfo.c
index ae8b8e7..a32a45a 100644
--- a/rpminfo.c
+++ b/rpminfo.c
@@ -399,22 +399,22 @@ PHP_FUNCTION(rpmdbsearch)
RETURN_THROWS();
}
- if (crit == RPMTAG_PKGID) {
+ if (crit == RPMTAG_INSTALLTID) {
+ tid = atol(name);
+ name = (char *)&tid;
+ len = sizeof(tid);
+ } else if (crit == RPMTAG_SIGMD5) {
if (len != 32) {
- zend_argument_value_error(1, "Bad length for PKGID, 32 expected");
+ zend_argument_value_error(1, "Bad length for PKGID/SIGMD5, 32 expected");
RETURN_THROWS();
}
len = hex2bin(name, MD5, len);
name = MD5;
- } else if (crit == RPMTAG_HDRID) {
+ } else if (crit == RPMTAG_SHA1HEADER) {
if (len != 40) {
- zend_argument_value_error(1, "Bad length for HDRID, 40 expected");
+ zend_argument_value_error(1, "Bad length for HDRID/SHA1HEADER, 40 expected");
RETURN_THROWS();
}
- } else if (crit == RPMTAG_INSTALLTID) {
- tid = atol(name);
- name = (char *)&tid;
- len = sizeof(tid);
} else if (crit == RPMTAG_INSTFILENAMES) {
/* use input parameters */
} else {