Lines Matching refs:len
330 assert_se(sizeof(option1) == sizeof(DHCP6Option) + be16toh(option->len)); in TEST()
332 …r = dhcp6_option_parse_ia(NULL, 0, be16toh(option->code), be16toh(option->len), option->data, &ia); in TEST()
335 …r = dhcp6_option_parse_ia(NULL, iaid, be16toh(option->code), be16toh(option->len), option->data, &… in TEST()
338 option->len = htobe16(17); in TEST()
339 …r = dhcp6_option_parse_ia(NULL, iaid, be16toh(option->code), be16toh(option->len), option->data, &… in TEST()
342 option->len = htobe16(sizeof(DHCP6Option)); in TEST()
343 …r = dhcp6_option_parse_ia(NULL, iaid, be16toh(option->code), be16toh(option->len), option->data, &… in TEST()
347 assert_se(sizeof(option2) == sizeof(DHCP6Option) + be16toh(option->len)); in TEST()
348 …r = dhcp6_option_parse_ia(NULL, iaid, be16toh(option->code), be16toh(option->len), option->data, &… in TEST()
352 assert_se(sizeof(option3) == sizeof(DHCP6Option) + be16toh(option->len)); in TEST()
353 …r = dhcp6_option_parse_ia(NULL, iaid, be16toh(option->code), be16toh(option->len), option->data, &… in TEST()
360 assert_se(sizeof(option4) == sizeof(DHCP6Option) + be16toh(option->len)); in TEST()
361 …r = dhcp6_option_parse_ia(NULL, iaid, be16toh(option->code), be16toh(option->len), option->data, &… in TEST()
371 assert_se(sizeof(option5) == sizeof(DHCP6Option) + be16toh(option->len)); in TEST()
372 …r = dhcp6_option_parse_ia(NULL, iaid, be16toh(option->code), be16toh(option->len), option->data, &… in TEST()
730 static void test_client_verify_information_request(const DHCP6Message *msg, size_t len) { in test_client_verify_information_request() argument
733 assert_se(len == sizeof(msg_information_request)); in test_client_verify_information_request()
735 assert_se(memcmp(msg, msg_information_request, len - sizeof(be16_t)) == 0); in test_client_verify_information_request()
738 static void test_client_verify_solicit(const DHCP6Message *msg, size_t len) { in test_client_verify_solicit() argument
741 assert_se(len == sizeof(msg_solicit)); in test_client_verify_solicit()
743 assert_se(memcmp(msg, msg_solicit, len - sizeof(be16_t)) == 0); in test_client_verify_solicit()
746 static void test_client_verify_request(const DHCP6Message *msg, size_t len) { in test_client_verify_request() argument
749 assert_se(len == sizeof(msg_request)); in test_client_verify_request()
752 …assert_se(memcmp(msg->options, msg_request + offsetof(DHCP6Message, options), len - offsetof(DHCP6… in test_client_verify_request()
761 size_t len; in test_lease_common() local
765 assert_se(dhcp6_lease_get_clientid(lease, &id, &len) >= 0); in test_lease_common()
766 assert_se(memcmp_nn(id, len, client_id, sizeof(client_id)) == 0); in test_lease_common()
797 size_t len; in test_lease_managed() local
801 assert_se(dhcp6_lease_get_serverid(lease, &id, &len) >= 0); in test_lease_managed()
802 assert_se(memcmp_nn(id, len, server_id, sizeof(server_id)) == 0); in test_lease_managed()
919 int dhcp6_network_send_udp_socket(int s, struct in6_addr *a, const void *packet, size_t len) { in dhcp6_network_send_udp_socket() argument
925 assert_se(len >= sizeof(DHCP6Message)); in dhcp6_network_send_udp_socket()
929 test_client_verify_information_request(packet, len); in dhcp6_network_send_udp_socket()
934 test_client_verify_solicit(packet, len); in dhcp6_network_send_udp_socket()
940 test_client_verify_request(packet, len); in dhcp6_network_send_udp_socket()
945 test_client_verify_solicit(packet, len); in dhcp6_network_send_udp_socket()
954 return len; in dhcp6_network_send_udp_socket()