diff options
author | jbj <devnull@localhost> | 2002-08-31 22:39:34 +0000 |
---|---|---|
committer | jbj <devnull@localhost> | 2002-08-31 22:39:34 +0000 |
commit | cc5d229b0e7a13f4d9efac2aed5926a0078df48c (patch) | |
tree | b5a1a608498f322dad0cd9534ccd9da4c121b3a0 /lib/rpmlead.c | |
parent | 929d5d38346273dbdaf20e5ceb3b1687405676af (diff) | |
download | rpm-cc5d229b0e7a13f4d9efac2aed5926a0078df48c.tar.gz rpm-cc5d229b0e7a13f4d9efac2aed5926a0078df48c.tar.bz2 rpm-cc5d229b0e7a13f4d9efac2aed5926a0078df48c.zip |
Sync with rpm-4.1.
CVS patchset: 5695
CVS date: 2002/08/31 22:39:34
Diffstat (limited to 'lib/rpmlead.c')
-rw-r--r-- | lib/rpmlead.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/rpmlead.c b/lib/rpmlead.c index 348517856..a679334c3 100644 --- a/lib/rpmlead.c +++ b/lib/rpmlead.c @@ -12,6 +12,7 @@ #include <rpmlib.h> +#include "signature.h" #include "rpmlead.h" #include "debug.h" @@ -59,13 +60,12 @@ rpmRC readLead(FD_t fd, struct rpmlead *lead) if (memcmp(lead->magic, lead_magic, sizeof(lead_magic))) return RPMRC_FAIL; - lead->type = ntohs(lead->type); lead->archnum = ntohs(lead->archnum); lead->osnum = ntohs(lead->osnum); - - if (lead->major >= 2) - lead->signature_type = ntohs(lead->signature_type); + lead->signature_type = ntohs(lead->signature_type); + if (lead->signature_type != RPMSIGTYPE_HEADERSIG) + return RPMRC_FAIL; return RPMRC_OK; } |