summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorAnas Nashif <anas.nashif@intel.com>2012-10-11 15:45:41 -0700
committerAnas Nashif <anas.nashif@intel.com>2013-02-02 16:44:15 -0800
commit83c6b463ad8ce39b4d4bc82d9259bc414017432f (patch)
treef477926237e718298530fbacc4895edec489e30e /lib
parent5196558fde38105636032f38e9d6be6e244fa753 (diff)
downloadrpm-83c6b463ad8ce39b4d4bc82d9259bc414017432f.tar.gz
rpm-83c6b463ad8ce39b4d4bc82d9259bc414017432f.tar.bz2
rpm-83c6b463ad8ce39b4d4bc82d9259bc414017432f.zip
Don't complain about a bad md5 sum for repackaged rpms.
Diffstat (limited to 'lib')
-rw-r--r--lib/psm.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/psm.c b/lib/psm.c
index aad047fcf..42a2ad46c 100644
--- a/lib/psm.c
+++ b/lib/psm.c
@@ -813,12 +813,17 @@ static rpmRC rpmpsmStage(rpmpsm psm, pkgStage stage)
rpmpsmNotify(psm, RPMCALLBACK_INST_PROGRESS, 0);
if (rpmfiFC(fi) > 0 && !(rpmtsFlags(ts) & RPMTRANS_FLAG_JUSTDB)) {
+ rpmtransFlags oldtsflags;
FD_t payload = rpmtePayload(psm->te);
if (payload == NULL) {
rc = RPMRC_FAIL;
break;
}
+ oldtsflags = rpmtsFlags(ts);
+ if (headerIsEntry(fi->h, RPMTAG_REMOVETID))
+ (void) rpmtsSetFlags(ts, oldtsflags | RPMTRANS_FLAG_NOMD5);
+
fsmrc = rpmPackageFilesInstall(psm->ts, psm->te, psm->fi,
payload, psm, &psm->failedFile);
@@ -827,6 +832,9 @@ static rpmRC rpmpsmStage(rpmpsm psm, pkgStage stage)
rpmswAdd(rpmtsOp(psm->ts, RPMTS_OP_DIGEST),
fdOp(payload, FDSTAT_DIGEST));
+ if (headerIsEntry(fi->h, RPMTAG_REMOVETID))
+ (void) rpmtsSetFlags(ts, oldtsflags);
+
Fclose(payload);
}