Lines Matching refs:i
48 for (int i = 0; i < 3; ++i) in test_localhost_bind() local
50 sockets[i] = xsocket in test_localhost_bind()
51 (ai[i]->ai_family, ai[i]->ai_socktype, ai[i]->ai_protocol); in test_localhost_bind()
52 xbind (sockets[i], ai[i]->ai_addr, ai[i]->ai_addrlen); in test_localhost_bind()
57 for (int i = 0; i < 3; ++i) in test_localhost_bind() local
59 TEST_VERIFY (sendto (client, &i, sizeof (i), 0, in test_localhost_bind()
60 ai[i]->ai_addr, ai[i]->ai_addrlen) == sizeof (i)); in test_localhost_bind()
61 int j = i + 256; in test_localhost_bind()
63 ai[i]->ai_addr, ai[i]->ai_addrlen) == sizeof (j)); in test_localhost_bind()
70 for (int i = 0; i < 3; ++i) in test_localhost_bind() local
73 TEST_VERIFY (recv (sockets[i], &buf, sizeof (buf), 0) == sizeof (buf)); in test_localhost_bind()
74 TEST_VERIFY (buf == i); in test_localhost_bind()
76 for (int i = 0; i < 3; ++i) in test_localhost_bind() local
79 TEST_VERIFY (recv (sockets[i], &buf, sizeof (buf), 0) == sizeof (buf)); in test_localhost_bind()
80 TEST_VERIFY (buf == i + 256); in test_localhost_bind()
82 TEST_VERIFY (recv (sockets[i], &buf, sizeof (buf), MSG_DONTWAIT) == -1); in test_localhost_bind()
87 for (int i = 0; i < 3; ++i) in test_localhost_bind() local
89 freeaddrinfo (ai[i]); in test_localhost_bind()
90 xclose (sockets[i]); in test_localhost_bind()