Fix 1452 - byte order issue in mg_check_ip_acl

This commit is contained in:
Sergey Lyubka committed 2022-01-21 12:24:58 +00:00
1 parent 1a8e3c2e31
commit 59c4dfa33b
3 files changed
+3 -3

No files matched your search

+1 -1
View File
@@ -1539,7 +1539,7 @@ static void test_udp(void) {
}
static void test_check_ip_acl(void) {
uint32_t ip = 0x01020304;
uint32_t ip = mg_htonl(0x01020304);
ASSERT(mg_check_ip_acl(mg_str(NULL), ip) == 1);
ASSERT(mg_check_ip_acl(mg_str(""), ip) == 1);
ASSERT(mg_check_ip_acl(mg_str("invalid"), ip) == -1);