diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/usr.bin/openssl/certhash.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/usr.bin/openssl/certhash.c b/src/usr.bin/openssl/certhash.c index a7a42d7f59..7458add906 100644 --- a/src/usr.bin/openssl/certhash.c +++ b/src/usr.bin/openssl/certhash.c | |||
| @@ -121,7 +121,8 @@ hashinfo_compare(const void *a, const void *b) | |||
| 121 | rv = hia->hash - hib->hash; | 121 | rv = hia->hash - hib->hash; |
| 122 | if (rv != 0) | 122 | if (rv != 0) |
| 123 | return (rv); | 123 | return (rv); |
| 124 | rv = bcmp(hia->fingerprint, hib->fingerprint, sizeof(hia->fingerprint)); | 124 | rv = memcmp(hia->fingerprint, hib->fingerprint, |
| 125 | sizeof(hia->fingerprint)); | ||
| 125 | if (rv != 0) | 126 | if (rv != 0) |
| 126 | return (rv); | 127 | return (rv); |
| 127 | return strcmp(hia->filename, hib->filename); | 128 | return strcmp(hia->filename, hib->filename); |
| @@ -404,7 +405,8 @@ certhash_index(struct hashinfo *head, const char *name) | |||
| 404 | for (entry = head; entry != NULL; entry = entry->next) { | 405 | for (entry = head; entry != NULL; entry = entry->next) { |
| 405 | if (last != NULL) { | 406 | if (last != NULL) { |
| 406 | if (entry->hash == last->hash) { | 407 | if (entry->hash == last->hash) { |
| 407 | if (bcmp(entry->fingerprint, last->fingerprint, | 408 | if (memcmp(entry->fingerprint, |
| 409 | last->fingerprint, | ||
| 408 | sizeof(entry->fingerprint)) == 0) { | 410 | sizeof(entry->fingerprint)) == 0) { |
| 409 | fprintf(stderr, "WARNING: duplicate %s " | 411 | fprintf(stderr, "WARNING: duplicate %s " |
| 410 | "in %s (using %s), ignoring...\n", | 412 | "in %s (using %s), ignoring...\n", |
