summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJindrich Novy <jnovy@redhat.com>2010-09-26 18:45:34 +0200
committerJindrich Novy <jnovy@redhat.com>2010-09-26 18:45:34 +0200
commit4c41013eeb43ccdcef1be37274d15721ec19799d (patch)
treedba0a1eff35236764b566b2bc557e9a23954df61
parentf7e058a01ea288d1c6810562b1238c05bfaa30bc (diff)
downloadrpm-4c41013eeb43ccdcef1be37274d15721ec19799d.tar.gz
rpm-4c41013eeb43ccdcef1be37274d15721ec19799d.tar.bz2
rpm-4c41013eeb43ccdcef1be37274d15721ec19799d.zip
Fix segfault in rpmdeps (RhBug:637357)
-rw-r--r--build/rpmfc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/build/rpmfc.c b/build/rpmfc.c
index 4c59a9537..f8494c800 100644
--- a/build/rpmfc.c
+++ b/build/rpmfc.c
@@ -765,7 +765,7 @@ rpmRC rpmfcApply(rpmfc fc)
int xx = 0;
/* Generate package and per-file dependencies. */
- for (fc->ix = 0; fc->fn[fc->ix] != NULL; fc->ix++) {
+ for (fc->ix = 0; fc->fn != NULL && fc->fn[fc->ix] != NULL; fc->ix++) {
for (ARGV_t fattr = fc->fattrs[fc->ix]; fattr && *fattr; fattr++) {
xx += rpmfcHelper(fc, 'P', *fattr);
xx += rpmfcHelper(fc, 'R', *fattr);