mirror of
https://github.com/openssl/openssl.git
synced 2026-01-25 02:56:43 +00:00
test: fix tests in lightof test_strn2_ removals
Reviewed-by: Norbert Pocs <norbertp@openssl.org> Reviewed-by: Nikola Pajkovsky <nikolap@openssl.org> Reviewed-by: Frederik Wedel-Heinen <fwh.openssl@gmail.com> (Merged from https://github.com/openssl/openssl/pull/29627)
This commit is contained in:
@@ -293,8 +293,8 @@ static int test_membio_str_eq(BIO *bio_provided, BIO *bio_legacy)
|
||||
|
||||
return TEST_long_ge(len_legacy, 0)
|
||||
&& TEST_long_ge(len_provided, 0)
|
||||
&& TEST_strn2_eq(str_provided, len_provided,
|
||||
str_legacy, len_legacy);
|
||||
&& TEST_size_t_eq(len_provided, len_legacy)
|
||||
&& TEST_strn_eq(str_provided, str_legacy, len_provided);
|
||||
}
|
||||
|
||||
static int test_protected_PEM(const char *keytype, int evp_type,
|
||||
|
||||
@@ -147,7 +147,7 @@ static int test_trace_channel(void)
|
||||
|
||||
ret = put_trace_output();
|
||||
len = BIO_get_mem_data(bio, &p_buf);
|
||||
if (!TEST_strn2_eq(p_buf, len, expected, expected_len))
|
||||
if (!TEST_size_t_eq(len, expected_len) || !TEST_strn_eq(p_buf, expected, len))
|
||||
ret = 0;
|
||||
ret = TEST_int_eq(OSSL_trace_set_channel(OSSL_TRACE_CATEGORY_HTTP, NULL), 1)
|
||||
&& ret;
|
||||
|
||||
Reference in New Issue
Block a user