From 3782d652156dd3067c09f0441bc087d2b4b790ff Mon Sep 17 00:00:00 2001 From: Panu Matilainen Date: Thu, 19 Jun 2008 15:51:07 +0300 Subject: [PATCH] Use type-specific headerPut() in rpmpsmStage() --- lib/psm.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/lib/psm.c b/lib/psm.c index a6a4383..ad2f619 100644 --- a/lib/psm.c +++ b/lib/psm.c @@ -1497,20 +1497,16 @@ assert(psm->mi == NULL); if (rpmtsFlags(ts) & RPMTRANS_FLAG_TEST) break; if (psm->goal == PSM_PKGINSTALL) { - struct rpmtd_s td; rpm_time_t installTime = (rpm_time_t) time(NULL); rpm_count_t fc = rpmfiFC(fi); if (fi->h == NULL) break; /* XXX can't happen */ if (fi->fstates != NULL && fc > 0) { - if (rpmtdFromUint8(&td, RPMTAG_FILESTATES, fi->fstates, fc)) - headerPut(fi->h, &td, HEADERPUT_DEFAULT); + headerPutChar(fi->h, RPMTAG_FILESTATES, fi->fstates, fc); } - if (rpmtdFromUint32(&td, RPMTAG_INSTALLTIME, &installTime, 1)) - headerPut(fi->h, &td, HEADERPUT_DEFAULT); - if (rpmtdFromUint32(&td, RPMTAG_INSTALLCOLOR, &tscolor, 1)) - headerPut(fi->h, &td, HEADERPUT_DEFAULT); + headerPutUint32(fi->h, RPMTAG_INSTALLTIME, &installTime, 1); + headerPutUint32(fi->h, RPMTAG_INSTALLCOLOR, &tscolor, 1); /* * If this package has already been installed, remove it from -- 2.7.4