diff options
author | Tomas Mraz <tomas@openssl.org> | 2022-09-30 11:32:41 +0200 |
---|---|---|
committer | Tomas Mraz <tomas@openssl.org> | 2022-10-07 20:44:36 +0200 |
commit | 19b6b5f4791e3531cd6d3aabc8706d590ade14b7 (patch) | |
tree | 58272a99d1791e4f9ffc27f43af6b18e78deb40b /test/bio_dgram_test.c | |
parent | fb8bdbe3eba83265586a44cda2ffc783611680d7 (diff) |
Fix older clang warning on initialization
We use memset() instead.
Reviewed-by: Hugo Landau <hlandau@openssl.org>
Reviewed-by: Paul Dale <pauli@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/19311)
Diffstat (limited to 'test/bio_dgram_test.c')
-rw-r--r-- | test/bio_dgram_test.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/test/bio_dgram_test.c b/test/bio_dgram_test.c index f2b1bb6f4b..1d7ce2773f 100644 --- a/test/bio_dgram_test.c +++ b/test/bio_dgram_test.c @@ -495,7 +495,7 @@ static int test_bio_dgram_pair(void) uint8_t scratch[2048 + 4], scratch2[2048]; uint32_t key[8]; size_t i, num_dgram, num_processed = 0; - BIO_MSG msgs[2] = {0}, rmsgs[2] = {0}; + BIO_MSG msgs[2], rmsgs[2]; BIO_ADDR *addr1 = NULL, *addr2 = NULL, *addr3 = NULL, *addr4 = NULL; struct in_addr in_local; size_t total = 0; @@ -504,6 +504,9 @@ static int test_bio_dgram_pair(void) | BIO_DGRAM_CAP_PROVIDES_SRC_ADDR | BIO_DGRAM_CAP_PROVIDES_DST_ADDR; + memset(msgs, 0, sizeof(msgs)); + memset(rmsgs, 0, sizeof(rmsgs)); + in_local.s_addr = ntohl(0x7f000001); for (i = 0; i < OSSL_NELEM(key); ++i) |