diff options
author | Panu Matilainen <pmatilai@redhat.com> | 2012-05-14 10:59:21 +0300 |
---|---|---|
committer | Panu Matilainen <pmatilai@redhat.com> | 2012-05-14 10:59:21 +0300 |
commit | e0c2d4c41edf1ee7000b622fac5b6b5d4d15f5bb (patch) | |
tree | a6dfa84206f355b076b86e33dbb5d2010f45db09 /build | |
parent | 2c0416811af443c49bd5c6f3ee3a7ef93033ca8e (diff) | |
download | librpm-tizen-e0c2d4c41edf1ee7000b622fac5b6b5d4d15f5bb.tar.gz librpm-tizen-e0c2d4c41edf1ee7000b622fac5b6b5d4d15f5bb.tar.bz2 librpm-tizen-e0c2d4c41edf1ee7000b622fac5b6b5d4d15f5bb.zip |
Only pass what's needed to parseForConfig()
- It doesn't need the entire filelist, just current file entry.
Diffstat (limited to 'build')
-rw-r--r-- | build/files.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/build/files.c b/build/files.c index 9459b0e84..8e233fc14 100644 --- a/build/files.c +++ b/build/files.c @@ -577,10 +577,10 @@ exit: /** * Parse %config from file manifest. * @param buf current spec file line - * @param fl package file tree walk data + * @param cur current file entry data * @return RPMRC_OK on success */ -static rpmRC parseForConfig(char * buf, FileList fl) +static rpmRC parseForConfig(char * buf, FileEntry cur) { char *p, *pe, *q = NULL; const char *name; @@ -589,7 +589,7 @@ static rpmRC parseForConfig(char * buf, FileList fl) if ((p = strstr(buf, (name = "%config"))) == NULL) return RPMRC_OK; - fl->cur.attrFlags |= RPMFILE_CONFIG; + cur->attrFlags |= RPMFILE_CONFIG; /* Erase "%config" token. */ for (pe = p; (pe-p) < strlen(name); pe++) @@ -623,9 +623,9 @@ static rpmRC parseForConfig(char * buf, FileList fl) if (*pe != '\0') *pe++ = '\0'; if (rstreq(p, "missingok")) { - fl->cur.attrFlags |= RPMFILE_MISSINGOK; + cur->attrFlags |= RPMFILE_MISSINGOK; } else if (rstreq(p, "noreplace")) { - fl->cur.attrFlags |= RPMFILE_NOREPLACE; + cur->attrFlags |= RPMFILE_NOREPLACE; } else { rpmlog(RPMLOG_ERR, _("Invalid %s token: %s\n"), name, p); goto exit; @@ -1792,7 +1792,7 @@ static rpmRC processPackageFiles(rpmSpec spec, rpmBuildPkgFlags pkgFlags, if (parseForVerify(buf, &fl.cur, &fl.def) || parseForAttr(buf, &fl.cur, &fl.def) || parseForDev(buf, &fl.cur) || - parseForConfig(buf, &fl) || + parseForConfig(buf, &fl.cur) || parseForLang(buf, &fl) || parseForCaps(buf, &fl) || parseForSimple(spec, pkg, buf, &fl, &fileName)) |