From 00a88dd5e6f83791e293309e3bed91cd50fda71f Mon Sep 17 00:00:00 2001 From: Silvan Calarco Date: Thu, 18 Feb 2016 19:50:44 +0100 Subject: [PATCH] Increase obsolete limit (OBSOLETE_MAX) from 256 to 1024 --- src/distromatic.c | 10 +++++----- src/include/distromatic.h | 2 ++ 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/src/distromatic.c b/src/distromatic.c index d565f67..c6973a8 100644 --- a/src/distromatic.c +++ b/src/distromatic.c @@ -244,16 +244,16 @@ handleObsoletedPackages(struct configTag *ct, int archidx) { struct providedList *prov = ct->providedlist_idx[archidx][0]; int i,j,k; - int obs[256]; + int obs[OBSOLETE_MAX]; char buf[PATH_MAX]; struct headerList *currheader; - + while (prov) { - - if (prov->numproviders > 256) { + + if (prov->numproviders > OBSOLETE_MAX) { return 1; } - + if (prov->numproviders > 1) { for (i = 0; i < prov->numproviders; i++) obs[i]=-1; for (i = 0; i < prov->numproviders; i++) diff --git a/src/include/distromatic.h b/src/include/distromatic.h index e27e220..ce19b8d 100644 --- a/src/include/distromatic.h +++ b/src/include/distromatic.h @@ -11,6 +11,8 @@ #include "globaldefs.h" #include "headerlist.h" +#define OBSOLETE_MAX 1024 + struct configDefaults { char *html_basedir; char *distribution_name;