aboutsummaryrefslogtreecommitdiffstats
path: root/URPM.xs
diff options
context:
space:
mode:
Diffstat (limited to 'URPM.xs')
-rw-r--r--URPM.xs2
1 files changed, 2 insertions, 0 deletions
diff --git a/URPM.xs b/URPM.xs
index b1c3f72..50091a8 100644
--- a/URPM.xs
+++ b/URPM.xs
@@ -1711,6 +1711,8 @@ Pkg_compare(pkg, evr)
croak("undefined package");
char *epoch = NULL, *version, *release;
+ if (!strncmp(evr, "URPM::Package=", 14))
+ croak("compare() must not be called with a package reference as argument; use compare_pkg() instead");
/* extract epoch and version from evr */
version = evr;