diff options
Diffstat (limited to 'lib')
-rw-r--r-- | lib/transaction.c | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/lib/transaction.c b/lib/transaction.c index 4cd67207c..1ed1f220b 100644 --- a/lib/transaction.c +++ b/lib/transaction.c @@ -570,7 +570,8 @@ assert(otherFi != NULL); } } else { /* Skip create on all but the first instance of a shared file */ - if (rpmfsGetAction(otherFs, otherFileNum) != FA_UNKNOWN) + rpmFileAction oaction = rpmfsGetAction(otherFs, otherFileNum); + if (oaction != FA_UNKNOWN && !XFA_SKIPPING(oaction)) rpmfsSetAction(fs, i, FA_SKIP); } @@ -758,6 +759,17 @@ static void skipInstallFiles(const rpmts ts, rpmte p) ix = rpmfiDX(fi); drc[ix]++; + /* + * Always skip %ghosts on install. + * XXX: Should we skip directory creation if there are only + * %ghosts in it? Traditionally we create the (empty) directory, so + * preserving that behavior for now at least: leave the refcount alone. + */ + if (rpmfiFFlags(fi) & RPMFILE_GHOST) { + rpmfsSetAction(fs, i, FA_SKIP); + continue; + } + /* Don't bother with skipped files */ if (XFA_SKIPPING(rpmfsGetAction(fs, i))) { drc[ix]--; dff[ix] = 1; |