Module Name: src
Committed By: martin
Date: Sat Dec 5 17:23:39 UTC 2009
Modified Files:
src/crypto/external/bsd/netpgp/dist/src/lib: ssh2pgp.c
Log Message:
printf format fixes to make it compile
To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 \
src/crypto/external/bsd/netpgp/dist/src/lib/ssh2pgp.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/crypto/external/bsd/netpgp/dist/src/lib/ssh2pgp.c
diff -u src/crypto/external/bsd/netpgp/dist/src/lib/ssh2pgp.c:1.1 src/crypto/external/bsd/netpgp/dist/src/lib/ssh2pgp.c:1.2
--- src/crypto/external/bsd/netpgp/dist/src/lib/ssh2pgp.c:1.1 Sat Dec 5 07:08:19 2009
+++ src/crypto/external/bsd/netpgp/dist/src/lib/ssh2pgp.c Sat Dec 5 17:23:39 2009
@@ -227,13 +227,13 @@
return 0;
}
(void)stat(f, &st);
- if ((buf = calloc(1, st.st_size)) == NULL) {
- (void) fprintf(stderr, "can't calloc %lld bytes for '%s'\n", st.st_size, f);
+ if ((buf = calloc(1, (size_t)st.st_size)) == NULL) {
+ (void) fprintf(stderr, "can't calloc %zu bytes for '%s'\n", (size_t)st.st_size, f);
bufgap_close(&bg);
return 0;
}
- if ((bin = calloc(1, st.st_size)) == NULL) {
- (void) fprintf(stderr, "can't calloc %lld bytes for '%s'\n", st.st_size, f);
+ if ((bin = calloc(1, (size_t)st.st_size)) == NULL) {
+ (void) fprintf(stderr, "can't calloc %zu bytes for '%s'\n", (size_t)st.st_size, f);
(void) free(buf);
bufgap_close(&bg);
return 0;
@@ -301,7 +301,7 @@
/* check for stragglers */
if (ok && bufgap_tell(&bg, BGFromEOF, BGByte) > 0) {
- printf("%lld bytes left\n", bufgap_tell(&bg, BGFromEOF, BGByte));
+ printf("%"PRIi64" bytes left\n", bufgap_tell(&bg, BGFromEOF, BGByte));
printf("[%s]\n", bufgap_getstr(&bg));
ok = 0;
}