Fix test case for a2i_IPADDRESS

Reviewed-by: Paul Dale <pauli@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/16201)
This commit is contained in:
Amir Mohammadi 2021-08-04 09:44:29 +04:30 committed by Tomas Mraz
parent 1a9411a30b
commit 9b887d5d5a

View File

@ -52,7 +52,6 @@ typedef struct {
const char *ipasc;
const char *data;
int length;
ASN1_OCTET_STRING ip;
} IP_TESTDATA;
static IP_TESTDATA a2i_ipaddress_tests[] = {
@ -72,8 +71,10 @@ static IP_TESTDATA a2i_ipaddress_tests[] = {
{"example.test", NULL, 0},
{"", NULL, 0},
{"1.2.3.4 ", "\x01\x02\x03\x04", 4},
{" 1.2.3.4", "\x01\x02\x03\x04", 4},
{" 1.2.3.4 ", "\x01\x02\x03\x04", 4},
{"1.2.3.4.example.test", NULL, 0},
{"1.2.3.4 ", NULL, 0},
};