aboutsummaryrefslogtreecommitdiffstats
path: root/URPM.xs
diff options
context:
space:
mode:
Diffstat (limited to 'URPM.xs')
-rw-r--r--URPM.xs18
1 files changed, 7 insertions, 11 deletions
diff --git a/URPM.xs b/URPM.xs
index 1d2c910..ae80f67 100644
--- a/URPM.xs
+++ b/URPM.xs
@@ -236,7 +236,7 @@ print_list_entry(char *buff, int sz, const char *name, rpmsenseFlags flags, cons
}
static int
-ranges_overlap(rpmsenseFlags aflags, char *sa, rpmsenseFlags bflags, char *sb, int b_nopromote) {
+ranges_overlap(rpmsenseFlags aflags, char *sa, rpmsenseFlags bflags, char *sb) {
if (!aflags || !bflags)
return 1; /* really faster to test it there instead of later */
else {
@@ -271,7 +271,7 @@ ranges_overlap(rpmsenseFlags aflags, char *sa, rpmsenseFlags bflags, char *sb, i
if (ea && eb)
sense = rpmvercmp(*ea ? ea : "0", *eb ? eb : "0");
else if (ea && *ea && atol(ea) > 0)
- sense = b_nopromote ? 1 : 0;
+ sense = 1;
else if (eb && *eb && atol(eb) > 0)
sense = -1;
/* now compare version and release if epoch has not been enough */
@@ -364,7 +364,6 @@ struct cb_overlap_s {
rpmsenseFlags flags;
char *evr;
int direction; /* indicate to compare the above at left or right to the iteration element */
- int b_nopromote;
};
static int
@@ -409,9 +408,9 @@ callback_list_str_overlap(char *s, int slen, const char *name, rpmsenseFlags fla
if (!strcmp(name, os->name)) {
/* perform overlap according to direction needed, negative for left */
if (os->direction < 0)
- result = ranges_overlap(os->flags, os->evr, flags, (char *) evr, os->b_nopromote);
+ result = ranges_overlap(os->flags, os->evr, flags, (char *) evr);
else
- result = ranges_overlap(flags, (char *) evr, os->flags, os->evr, os->b_nopromote);
+ result = ranges_overlap(flags, (char *) evr, os->flags, os->evr);
}
/* fprintf(stderr, "cb_list_str_overlap result=%d, os->direction=%d, os->name=%s, os->evr=%s, name=%s, evr=%s\n",
@@ -1979,10 +1978,9 @@ Pkg_obsoletes_nosense(pkg)
SPAGAIN;
int
-Pkg_obsoletes_overlap(pkg, s, b_nopromote=1, direction=-1)
+Pkg_obsoletes_overlap(pkg, s, direction=-1)
URPM::Package pkg
char *s
- int b_nopromote
int direction
ALIAS:
provides_overlap = 1
@@ -2022,7 +2020,6 @@ Pkg_obsoletes_overlap(pkg, s, b_nopromote=1, direction=-1)
} else
os.evr = "";
os.direction = direction;
- os.b_nopromote = b_nopromote;
/* mark end of name */
if (eon) {
eonc = *eon;
@@ -2931,10 +2928,9 @@ rpmvercmp(one, two)
char *two
int
-Urpm_ranges_overlap(a, b, b_nopromote=1)
+Urpm_ranges_overlap(a, b)
char *a
char *b
- int b_nopromote
PREINIT:
char *sa = a, *sb = b;
int aflags = 0, bflags = 0;
@@ -2964,7 +2960,7 @@ Urpm_ranges_overlap(a, b, b_nopromote=1)
else break;
++sb;
}
- RETVAL = ranges_overlap(aflags, sa, bflags, sb, b_nopromote);
+ RETVAL = ranges_overlap(aflags, sa, bflags, sb);
}
OUTPUT:
RETVAL