Lines Matching refs:res
228 struct zsock_addrinfo *res = NULL; in ZTEST() local
238 (void)zsock_getaddrinfo(QUERY_HOST, NULL, NULL, &res); in ZTEST()
247 zsock_freeaddrinfo(res); in ZTEST()
252 struct zsock_addrinfo *res = NULL; in ZTEST() local
255 ret = zsock_getaddrinfo(QUERY_HOST, NULL, NULL, &res); in ZTEST()
267 zsock_freeaddrinfo(res); in ZTEST()
272 struct zsock_addrinfo *res = NULL; in ZTEST() local
275 ret = zsock_getaddrinfo(NULL, NULL, NULL, &res); in ZTEST()
279 zassert_is_null(res, "ai_addr is not NULL"); in ZTEST()
281 zsock_freeaddrinfo(res); in ZTEST()
286 struct zsock_addrinfo *res = NULL; in ZTEST() local
295 ret = zsock_getaddrinfo("1.2.3.255", "65534", NULL, &res); in ZTEST()
298 zassert_not_null(res, ""); in ZTEST()
299 zassert_is_null(res->ai_next, ""); in ZTEST()
300 zassert_equal(res->ai_family, AF_INET, ""); in ZTEST()
301 zassert_equal(res->ai_socktype, SOCK_STREAM, ""); in ZTEST()
302 zassert_equal(res->ai_protocol, IPPROTO_TCP, ""); in ZTEST()
303 zsock_freeaddrinfo(res); in ZTEST()
305 ret = zsock_getaddrinfo("1.2.3.255", "65534", &hints, &res); in ZTEST()
307 zassert_not_null(res, ""); in ZTEST()
308 zassert_is_null(res->ai_next, ""); in ZTEST()
309 zassert_equal(res->ai_family, AF_INET, ""); in ZTEST()
310 zassert_equal(res->ai_socktype, SOCK_STREAM, ""); in ZTEST()
311 zassert_equal(res->ai_protocol, IPPROTO_TCP, ""); in ZTEST()
312 zsock_freeaddrinfo(res); in ZTEST()
315 ret = zsock_getaddrinfo("1.2.3.255", "65534", &hints, &res); in ZTEST()
317 zassert_not_null(res, ""); in ZTEST()
318 zassert_is_null(res->ai_next, ""); in ZTEST()
319 zassert_equal(res->ai_family, AF_INET, ""); in ZTEST()
320 zassert_equal(res->ai_socktype, SOCK_DGRAM, ""); in ZTEST()
321 zassert_equal(res->ai_protocol, IPPROTO_UDP, ""); in ZTEST()
323 saddr = (struct sockaddr_in *)res->ai_addr; in ZTEST()
330 zsock_freeaddrinfo(res); in ZTEST()
335 struct zsock_addrinfo *res = NULL; in ZTEST() local
345 "65534", NULL, &res); in ZTEST()
348 zassert_not_null(res, ""); in ZTEST()
349 zassert_is_null(res->ai_next, ""); in ZTEST()
350 zassert_equal(res->ai_family, AF_INET6, ""); in ZTEST()
351 zassert_equal(res->ai_socktype, SOCK_STREAM, ""); in ZTEST()
352 zassert_equal(res->ai_protocol, IPPROTO_TCP, ""); in ZTEST()
354 saddr = (struct sockaddr_in6 *)res->ai_addr; in ZTEST()
373 zsock_freeaddrinfo(res); in ZTEST()
377 "65534", &hints, &res); in ZTEST()
379 zassert_not_null(res, ""); in ZTEST()
380 zassert_is_null(res->ai_next, ""); in ZTEST()
381 zassert_equal(res->ai_family, AF_INET6, ""); in ZTEST()
382 zassert_equal(res->ai_socktype, SOCK_STREAM, ""); in ZTEST()
383 zassert_equal(res->ai_protocol, IPPROTO_TCP, ""); in ZTEST()
385 saddr = (struct sockaddr_in6 *)res->ai_addr; in ZTEST()
404 zsock_freeaddrinfo(res); in ZTEST()
409 "65534", &hints, &res); in ZTEST()
411 zassert_not_null(res, ""); in ZTEST()
412 zassert_is_null(res->ai_next, ""); in ZTEST()
413 zassert_equal(res->ai_family, AF_INET6, ""); in ZTEST()
414 zassert_equal(res->ai_socktype, SOCK_DGRAM, ""); in ZTEST()
415 zassert_equal(res->ai_protocol, IPPROTO_UDP, ""); in ZTEST()
417 saddr = (struct sockaddr_in6 *)res->ai_addr; in ZTEST()
436 zsock_freeaddrinfo(res); in ZTEST()
440 "65534", &hints, &res); in ZTEST()
443 saddr = (struct sockaddr_in6 *)res->ai_addr; in ZTEST()
462 zsock_freeaddrinfo(res); in ZTEST()
465 ret = zsock_getaddrinfo("[::192.9.5.5]", "65534", &hints, &res); in ZTEST()
468 saddr = (struct sockaddr_in6 *)res->ai_addr; in ZTEST()
487 zsock_freeaddrinfo(res); in ZTEST()
491 "65534", &hints, &res); in ZTEST()
494 saddr = (struct sockaddr_in6 *)res->ai_addr; in ZTEST()
513 zsock_freeaddrinfo(res); in ZTEST()
517 "65534", &hints, &res); in ZTEST()
520 saddr = (struct sockaddr_in6 *)res->ai_addr; in ZTEST()
539 zsock_freeaddrinfo(res); in ZTEST()
545 struct zsock_addrinfo *res = NULL; in ZTEST() local
550 ret = zsock_getaddrinfo("foo.bar", "65534", &hints, &res); in ZTEST()
552 zassert_is_null(res, ""); in ZTEST()
554 ret = zsock_getaddrinfo("1.2.3.4", "65534", &hints, &res); in ZTEST()
556 zassert_not_null(res, ""); in ZTEST()
558 zsock_freeaddrinfo(res); in ZTEST()
563 struct zsock_addrinfo *res = NULL; in ZTEST() local
569 ret = zsock_getaddrinfo("192.0.2.1", NULL, &hints, &res); in ZTEST()
571 zassert_is_null(res, ""); in ZTEST()
572 zsock_freeaddrinfo(res); in ZTEST()
577 struct zsock_addrinfo *res = NULL; in ZTEST() local
583 ret = zsock_getaddrinfo("2001:db8::1", NULL, &hints, &res); in ZTEST()
585 zassert_is_null(res, ""); in ZTEST()
586 zsock_freeaddrinfo(res); in ZTEST()
592 struct zsock_addrinfo *res = NULL; in ZTEST() local
593 ret = zsock_getaddrinfo("192.0.2.1", "70000", NULL, &res); in ZTEST()
595 zassert_is_null(res, ""); in ZTEST()
596 zsock_freeaddrinfo(res); in ZTEST()
603 struct zsock_addrinfo *res = NULL; in ZTEST() local
612 ret = zsock_getaddrinfo(NULL, "80", &hints, &res); in ZTEST()
614 zassert_not_null(res, ""); in ZTEST()
615 zassert_is_null(res->ai_next, ""); in ZTEST()
616 zassert_equal(res->ai_family, AF_INET, ""); in ZTEST()
617 zassert_equal(res->ai_socktype, SOCK_STREAM, ""); in ZTEST()
618 zassert_equal(res->ai_protocol, IPPROTO_TCP, ""); in ZTEST()
619 saddr = net_sin(res->ai_addr); in ZTEST()
623 zsock_freeaddrinfo(res); in ZTEST()
627 ret = zsock_getaddrinfo(NULL, "80", &hints, &res); in ZTEST()
629 zassert_not_null(res, ""); in ZTEST()
630 zassert_is_null(res->ai_next, ""); in ZTEST()
631 zassert_equal(res->ai_family, AF_INET6, ""); in ZTEST()
632 zassert_equal(res->ai_socktype, SOCK_STREAM, ""); in ZTEST()
633 zassert_equal(res->ai_protocol, IPPROTO_TCP, ""); in ZTEST()
634 saddr6 = net_sin6(res->ai_addr); in ZTEST()
638 zsock_freeaddrinfo(res); in ZTEST()
642 ret = zsock_getaddrinfo(NULL, "80", &hints, &res); in ZTEST()
644 zassert_not_null(res, ""); in ZTEST()
645 zassert_is_null(res->ai_next, ""); in ZTEST()
646 zassert_equal(res->ai_family, AF_INET6, ""); in ZTEST()
647 zassert_equal(res->ai_socktype, SOCK_DGRAM, ""); in ZTEST()
648 zassert_equal(res->ai_protocol, IPPROTO_UDP, ""); in ZTEST()
649 saddr6 = (struct sockaddr_in6 *)res->ai_addr; in ZTEST()
652 zsock_freeaddrinfo(res); in ZTEST()
656 ret = zsock_getaddrinfo(NULL, "80", &hints, &res); in ZTEST()
658 zassert_not_null(res, ""); in ZTEST()
659 zassert_is_null(res->ai_next, ""); in ZTEST()
660 zassert_equal(res->ai_family, AF_INET, ""); in ZTEST()
661 zassert_equal(res->ai_socktype, SOCK_DGRAM, ""); in ZTEST()
662 zassert_equal(res->ai_protocol, IPPROTO_UDP, ""); in ZTEST()
663 saddr = (struct sockaddr_in *)res->ai_addr; in ZTEST()
666 zsock_freeaddrinfo(res); in ZTEST()