From b2402702ae91a73f7e4a4787b6a170357e219533 Mon Sep 17 00:00:00 2001 From: jbj Date: Sat, 21 Dec 2002 01:31:24 +0000 Subject: [PATCH] splint fiddles. CVS patchset: 5956 CVS date: 2002/12/21 01:31:24 --- build/rpmfc.h | 2 ++ lib/formats.c | 4 ++-- lib/rpmfi.c | 11 ++++++----- lib/rpmfi.h | 2 +- 4 files changed, 11 insertions(+), 8 deletions(-) diff --git a/build/rpmfc.h b/build/rpmfc.h index 4413d20..a041926 100644 --- a/build/rpmfc.h +++ b/build/rpmfc.h @@ -115,9 +115,11 @@ int rpmfcColoring(const char * fmstr) /** * @param fc file classifier */ +/*@-exportlocal@*/ void rpmfcPrint(const char * msg, rpmfc fc, FILE * fp) /*@globals fileSystem @*/ /*@modifies *fp, fc, fileSystem @*/; +/*@=exportlocal@*/ /** * Destroy a file classifier. diff --git a/lib/formats.c b/lib/formats.c index 99b6303..ce6c1f1 100644 --- a/lib/formats.c +++ b/lib/formats.c @@ -747,7 +747,7 @@ static int fileclassTag(Header h, /*@out@*/ rpmTagType * type, static int fileprovideTag(Header h, /*@out@*/ rpmTagType * type, /*@out@*/ const void ** data, /*@out@*/ int_32 * count, /*@out@*/ int * freeData) - /*@modifies *type, *data, *count, *freeData @*/ + /*@modifies h, *type, *data, *count, *freeData @*/ /*@requires maxSet(type) >= 0 /\ maxSet(data) >= 0 /\ maxSet(count) >= 0 /\ maxSet(freeData) >= 0 @*/ { @@ -769,7 +769,7 @@ static int fileprovideTag(Header h, /*@out@*/ rpmTagType * type, static int filerequireTag(Header h, /*@out@*/ rpmTagType * type, /*@out@*/ const void ** data, /*@out@*/ int_32 * count, /*@out@*/ int * freeData) - /*@modifies *type, *data, *count, *freeData @*/ + /*@modifies h, *type, *data, *count, *freeData @*/ /*@requires maxSet(type) >= 0 /\ maxSet(data) >= 0 /\ maxSet(count) >= 0 /\ maxSet(freeData) >= 0 @*/ { diff --git a/lib/rpmfi.c b/lib/rpmfi.c index d9ddb5f..5f81086 100644 --- a/lib/rpmfi.c +++ b/lib/rpmfi.c @@ -1227,7 +1227,8 @@ void rpmfiBuildFDeps(Header h, rpmTag tagN, size_t nb; rpmTagType ddt, fxt, fnt; char * t; - int dx, ndx, i, ix, xx; + unsigned ix; + int dx, ndx, i, xx; if (!hge(h, RPMTAG_FILESIZES, NULL, (void **) NULL, &ac) || ac == 0) { if (fdepsp) *fdepsp = NULL; @@ -1261,11 +1262,11 @@ void rpmfiBuildFDeps(Header h, rpmTag tagN, ix = ddict[dx++]; mydt = ((ix >> 24) & 0xff); if (mydt != deptype) - continue; + /*@innercontinue@*/ continue; ix &= 0x00ffffff; (void) rpmdsSetIx(ds, ix-1); if (rpmdsNext(ds) < 0) - continue; + /*@innercontinue@*/ continue; DNEVR = rpmdsDNEVR(ds); if (DNEVR != NULL) nb += strlen(DNEVR+2) + 1; @@ -1287,11 +1288,11 @@ void rpmfiBuildFDeps(Header h, rpmTag tagN, ix = ddict[dx++]; mydt = ((ix >> 24) & 0xff); if (mydt != deptype) - continue; + /*@innercontinue@*/ continue; ix &= 0x00ffffff; (void) rpmdsSetIx(ds, ix-1); if (rpmdsNext(ds) < 0) - continue; + /*@innercontinue@*/ continue; DNEVR = rpmdsDNEVR(ds); if (DNEVR != NULL) { t = stpcpy(t, DNEVR+2); diff --git a/lib/rpmfi.h b/lib/rpmfi.h index 3698a67..2ac8924 100644 --- a/lib/rpmfi.h +++ b/lib/rpmfi.h @@ -454,7 +454,7 @@ void rpmfiBuildFClasses(Header h, */ void rpmfiBuildFDeps(Header h, rpmTag tagN, /*@out@*/ const char *** fdepsp, /*@out@*/ int * fcp) - /*@modifies *fdepsp, *fcp @*/; + /*@modifies h, *fdepsp, *fcp @*/; /** * Return file type from mode_t. -- 2.7.4