Skip to content

Commit

Permalink
upstream commit
Browse files Browse the repository at this point in the history
correct fmt-string for size_t as noted by Nicholas
 Lemonias; ok djm@
  • Loading branch information
mfriedl authored and djmdjm committed Mar 27, 2015
1 parent a22b9ef commit df100be
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions hmac.c
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/* $OpenBSD: hmac.c,v 1.11 2015/01/15 21:37:14 markus Exp $ */
/* $OpenBSD: hmac.c,v 1.12 2015/03/24 20:03:44 markus Exp $ */
/*
* Copyright (c) 2014 Markus Friedl. All rights reserved.
*
Expand Down Expand Up @@ -154,7 +154,7 @@ hmac_test(void *key, size_t klen, void *m, size_t mlen, u_char *e, size_t elen)

if (memcmp(e, digest, elen)) {
for (i = 0; i < elen; i++)
printf("[%zd] %2.2x %2.2x\n", i, e[i], digest[i]);
printf("[%zu] %2.2x %2.2x\n", i, e[i], digest[i]);
printf("mismatch\n");
} else
printf("ok\n");
Expand Down
4 changes: 2 additions & 2 deletions sshbuf-misc.c
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/* $OpenBSD: sshbuf-misc.c,v 1.3 2015/02/05 12:59:57 millert Exp $ */
/* $OpenBSD: sshbuf-misc.c,v 1.4 2015/03/24 20:03:44 markus Exp $ */
/*
* Copyright (c) 2011 Damien Miller
*
Expand Down Expand Up @@ -42,7 +42,7 @@ sshbuf_dump_data(const void *s, size_t len, FILE *f)
const u_char *p = (const u_char *)s;

for (i = 0; i < len; i += 16) {
fprintf(f, "%.4zd: ", i);
fprintf(f, "%.4zu: ", i);
for (j = i; j < i + 16; j++) {
if (j < len)
fprintf(f, "%02x ", p[j]);
Expand Down

0 comments on commit df100be

Please sign in to comment.