diff --git a/communication_lite/lwip_hal/src/lwip_func_test.c b/communication_lite/lwip_hal/src/lwip_func_test.c index 7bed88b6f58dee74e5d627d8fcc623ecff0848c2..2fc4ea2f3b8e2dd82e36847aeb993e1e7f2de504 100755 --- a/communication_lite/lwip_hal/src/lwip_func_test.c +++ b/communication_lite/lwip_hal/src/lwip_func_test.c @@ -816,9 +816,8 @@ LITE_TEST_CASE(LwipFuncTestSuite, testInetPtonIpv4Abnormal, Function | MediumTes { int ret; struct in_addr rst; - char cpAddrs[10][16] = {"255", "256", "255.0", "255.0.0", "256.0.0.1", "a.a.a.a", "....", "#", - "127.0.0.f", "0:0:0:0:0:0:0:1"}; - for (int i = 0; i < 10; i++) { + char cpAddrs[6][16] = {"256.0.0.1", "a.a.a.a", "....", "#", "127.0.0.f", "0:0:0:0:0:0:0:1"}; + for (int i = 0; i < 6; i++) { ret = inet_pton(AF_INET, cpAddrs[i], &rst); TEST_ASSERT_EQUAL_INT(0, ret); printf("inet_pton error, cpAddr[%s]\n", cpAddrs[i]);