diff options
-rw-r--r-- | lib/signature.c | 16 | ||||
-rw-r--r-- | lib/signature.h | 2 | ||||
-rw-r--r-- | rpmio/rpmpgp.h | 4 |
3 files changed, 11 insertions, 11 deletions
diff --git a/lib/signature.c b/lib/signature.c index 1da1a78f1..c465cd8ff 100644 --- a/lib/signature.c +++ b/lib/signature.c @@ -342,7 +342,7 @@ Header rpmFreeSignature(Header sigh) * @param passPhrase private key pass phrase * @return 0 on success, 1 on failure */ -static int makePGPSignature(const char * file, int32_t * sigTagp, +static int makePGPSignature(const char * file, rpm_tag_t * sigTagp, uint8_t ** pktp, size_t * pktlenp, const char * passPhrase) { @@ -473,7 +473,7 @@ static int makePGPSignature(const char * file, int32_t * sigTagp, * @param passPhrase private key pass phrase * @return 0 on success, 1 on failure */ -static int makeGPGSignature(const char * file, int32_t * sigTagp, +static int makeGPGSignature(const char * file, rpm_tag_t * sigTagp, uint8_t ** pktp, size_t * pktlenp, const char * passPhrase) { @@ -608,13 +608,13 @@ static int makeGPGSignature(const char * file, int32_t * sigTagp, * @param passPhrase private key pass phrase * @return 0 on success, -1 on failure */ -static int makeHDRSignature(Header sigh, const char * file, int32_t sigTag, +static int makeHDRSignature(Header sigh, const char * file, rpm_tag_t sigTag, const char * passPhrase) { Header h = NULL; FD_t fd = NULL; uint8_t * pkt; - rpm_count_t pktlen; + size_t pktlen; const char * fn = NULL; const char * SHA1 = NULL; int ret = -1; /* assume failure. */ @@ -711,12 +711,12 @@ exit: return ret; } -int rpmAddSignature(Header sigh, const char * file, int32_t sigTag, +int rpmAddSignature(Header sigh, const char * file, rpm_tag_t sigTag, const char * passPhrase) { struct stat st; uint8_t * pkt; - rpm_count_t pktlen; + size_t pktlen; int ret = -1; /* assume failure. */ switch (sigTag) { @@ -764,7 +764,7 @@ int rpmAddSignature(Header sigh, const char * file, int32_t sigTag, return ret; } -static int checkPassPhrase(const char * passPhrase, const int sigTag) +static int checkPassPhrase(const char * passPhrase, const rpm_tag_t sigTag) { int passPhrasePipe[2]; int pid, status; @@ -861,7 +861,7 @@ static int checkPassPhrase(const char * passPhrase, const int sigTag) return ((!WIFEXITED(status) || WEXITSTATUS(status)) ? 1 : 0); } -char * rpmGetPassPhrase(const char * prompt, const int sigTag) +char * rpmGetPassPhrase(const char * prompt, const rpm_tag_t sigTag) { char *pass = NULL; int aok = 0; diff --git a/lib/signature.h b/lib/signature.h index 213156e27..d02580cbb 100644 --- a/lib/signature.h +++ b/lib/signature.h @@ -65,7 +65,7 @@ int rpmWriteSignature(FD_t fd, Header h); * @return 0 on success, -1 on failure */ int rpmAddSignature(Header sigh, const char * file, - int32_t sigTag, const char * passPhrase); + rpm_tag_t sigTag, const char * passPhrase); /******************************************************************/ diff --git a/rpmio/rpmpgp.h b/rpmio/rpmpgp.h index 30e3b9b3f..7730b6d56 100644 --- a/rpmio/rpmpgp.h +++ b/rpmio/rpmpgp.h @@ -999,7 +999,7 @@ size_t pgpLen(const uint8_t *s, size_t * lenp) (*lenp) = ((((unsigned)s[0]) - 192) << 8) + s[1] + 192; return 2; } else { - (*lenp) = pgpGrab(s+1, 4); + (*lenp) = pgpGrab(s+1, (size_t) 4); return 5; } } @@ -1074,7 +1074,7 @@ const char * pgpMpiStr(const uint8_t *p) { static char prbuf[8*BUFSIZ]; /* XXX ick */ char *t = prbuf; - sprintf(t, "[%4u]: ", pgpGrab(p, 2)); + sprintf(t, "[%4u]: ", pgpGrab(p, (size_t) 2)); t += strlen(t); t = pgpHexCvt(t, p+2, pgpMpiLen(p)-2); return prbuf; |