summaryrefslogtreecommitdiff
path: root/build/files.c
diff options
context:
space:
mode:
authorjbj <devnull@localhost>2001-11-06 22:46:26 +0000
committerjbj <devnull@localhost>2001-11-06 22:46:26 +0000
commite680cce3e8a80425586c6e2448f57a48606d220b (patch)
tree663ce322c8de2bca7fa05171e76e30d9ca80c7ab /build/files.c
parent0724785fb3a9b4d4fc1d10c6e6238b70f9752c56 (diff)
downloadrpm-e680cce3e8a80425586c6e2448f57a48606d220b.tar.gz
rpm-e680cce3e8a80425586c6e2448f57a48606d220b.tar.bz2
rpm-e680cce3e8a80425586c6e2448f57a48606d220b.zip
- fix: harmless typo in db3 chroot hack.
- fix: big-endian's with sizeof(time_t) != sizeof(int_32) mtime broken. - fix: add Korean message catalogs (#54473). - add RPHNPLATFORM and PLATFORM tags. - linear search on added package provides is dumb. - discarding entire signature header when using --addsign is dumb. CVS patchset: 5159 CVS date: 2001/11/06 22:46:26
Diffstat (limited to 'build/files.c')
-rw-r--r--build/files.c16
1 files changed, 14 insertions, 2 deletions
diff --git a/build/files.c b/build/files.c
index 45e1536b2..450761eab 100644
--- a/build/files.c
+++ b/build/files.c
@@ -1217,8 +1217,14 @@ static void genCpioListAndHeader(/*@partial@*/ FileList fl,
&(flp->uname), 1);
(void) headerAddOrAppendEntry(h, RPMTAG_FILEGROUPNAME, RPM_STRING_ARRAY_TYPE,
&(flp->gname), 1);
+ if (sizeof(flp->fl_mtime) != sizeof(uint_32)) {
+ uint_32 mtime = (uint_32)flp->fl_mtime;
+ (void) headerAddOrAppendEntry(h, RPMTAG_FILEMTIMES, RPM_INT32_TYPE,
+ &(mtime), 1);
+ } else {
(void) headerAddOrAppendEntry(h, RPMTAG_FILEMTIMES, RPM_INT32_TYPE,
&(flp->fl_mtime), 1);
+ }
if (sizeof(flp->fl_mode) != sizeof(uint_16)) {
uint_16 pmode = (uint_16)flp->fl_mode;
(void) headerAddOrAppendEntry(h, RPMTAG_FILEMODES, RPM_INT16_TYPE,
@@ -1243,9 +1249,15 @@ static void genCpioListAndHeader(/*@partial@*/ FileList fl,
(void) headerAddOrAppendEntry(h, RPMTAG_FILEDEVICES, RPM_INT32_TYPE,
&(flp->fl_dev), 1);
}
-/*@=sizeoftype@*/
+ if (sizeof(flp->fl_ino) != sizeof(uint_32)) {
+ uint_32 ino = (uint_32)flp->fl_ino;
(void) headerAddOrAppendEntry(h, RPMTAG_FILEINODES, RPM_INT32_TYPE,
- &(flp->fl_ino), 1);
+ &(ino), 1);
+ } else {
+ (void) headerAddOrAppendEntry(h, RPMTAG_FILEINODES, RPM_INT32_TYPE,
+ &(flp->fl_ino), 1);
+ }
+/*@=sizeoftype@*/
(void) headerAddOrAppendEntry(h, RPMTAG_FILELANGS, RPM_STRING_ARRAY_TYPE,
&(flp->langs), 1);