/external/ltp/utils/sctp/func_tests/ |
D | test_tcp_style.c | 63 int clt_sk[MAX_CLIENTS], accept_sk[MAX_CLIENTS]; in main() local 127 clt_sk[i] = test_socket(pf_class, SOCK_STREAM, IPPROTO_SCTP); in main() 128 test_bind(clt_sk[i], &clt_loop[i].sa, sizeof(clt_loop[i])); in main() 135 error = accept(clt_sk[0], &accept_loop.sa, &addrlen); in main() 153 test_connect(clt_sk[i], &svr_loop.sa, sizeof(svr_loop)); in main() 199 error = accept(clt_sk[0], &accept_loop.sa, &addrlen); in main() 210 test_send(clt_sk[i], message, strlen(message), 0); in main() 221 test_recv(clt_sk[i], msgbuf, 100, 0); in main() 247 test_enable_assoc_change(clt_sk[0]); in main() 250 test_shutdown(clt_sk[0], SHUT_WR); in main() [all …]
|
D | test_recvmsg.c | 64 int svr_sk, clt_sk; in main() local 94 clt_sk = test_socket(AF_INET, SOCK_SEQPACKET, IPPROTO_SCTP); in main() 95 test_bind(clt_sk, (struct sockaddr *)&clt_loop, sizeof(clt_loop)); in main() 99 test_enable_assoc_change(clt_sk); in main() 110 test_sendmsg(clt_sk, &outmessage, 0, 30000); in main() 123 error = test_recvmsg(clt_sk, &inmessage, 0); in main() 156 close(clt_sk); in main()
|
D | test_peeloff.c | 64 int svr_sk, clt_sk[MAX_CLIENTS], peeloff_sk[MAX_CLIENTS]; in main() local 113 clt_sk[i] = test_socket(pf_class, SOCK_SEQPACKET, IPPROTO_SCTP); in main() 123 test_bind(clt_sk[i], &clt_loop[i].sa, sizeof(clt_loop[i])); in main() 125 test_enable_assoc_change(clt_sk[i]); in main() 152 test_sendmsg(clt_sk[i], &outmessage, 0, in main() 167 error = test_recvmsg(clt_sk[i], &inmessage, MSG_WAITALL); in main() 226 test_sendmsg(clt_sk[i], &outmessage, 0, strlen(message)+1); in main() 252 error = test_recvmsg(clt_sk[i], &inmessage, MSG_WAITALL); in main() 271 error = test_recvmsg(clt_sk[0], &inmessage, MSG_WAITALL); in main() 288 error = test_recvmsg(clt_sk[i], &inmessage, MSG_WAITALL); in main() [all …]
|
D | test_1_to_1_events.c | 55 int svr_sk, clt_sk,acpt_sk; in main() local 93 clt_sk = test_socket(AF_INET, SOCK_STREAM, IPPROTO_SCTP); in main() 100 test_setsockopt(clt_sk, SCTP_EVENTS, &event, len); in main() 103 test_connect(clt_sk, (struct sockaddr *) &clt_loop, len); in main() 134 test_sendmsg(clt_sk, &outmessage, 0, strlen(message)+1); in main() 151 error = test_recvmsg(clt_sk, &inmessage, MSG_WAITALL); in main() 177 close(clt_sk); in main()
|
D | test_assoc_shutdown.c | 65 int svr_sk, clt_sk[MAX_CLIENTS]; in main() local 107 clt_sk[i] = test_socket(AF_INET, SOCK_SEQPACKET, IPPROTO_SCTP); in main() 112 test_bind(clt_sk[i], &clt_loop[i].sa, sizeof(clt_loop[i])); in main() 114 test_enable_assoc_change(clt_sk[i]); in main() 143 test_sendmsg(clt_sk[i], &outmessage, 0, strlen(message)+1); in main() 157 error = test_recvmsg(clt_sk[i], &inmessage, MSG_WAITALL); in main() 233 error = test_recvmsg(clt_sk[i], &inmessage, MSG_WAITALL); in main() 239 close(clt_sk[i]); in main()
|
D | test_assoc_abort.c | 66 int svr_sk, clt_sk[MAX_CLIENTS]; in main() local 107 clt_sk[i] = test_socket(AF_INET, SOCK_SEQPACKET, IPPROTO_SCTP); in main() 112 test_bind(clt_sk[i], &clt_loop[i].sa, sizeof(clt_loop[i])); in main() 114 test_enable_assoc_change(clt_sk[i]); in main() 143 test_sendmsg(clt_sk[i], &outmessage, 0, strlen(message) + 1); in main() 157 error = test_recvmsg(clt_sk[i], &inmessage, MSG_WAITALL); in main() 232 error = test_recvmsg(clt_sk[i], &inmessage, MSG_WAITALL); in main() 237 close(clt_sk[i]); in main()
|
D | test_getname.c | 62 int clt_sk, svr_sk, accept_sk; in main() local 117 clt_sk = test_socket(pf_class, SOCK_STREAM, IPPROTO_SCTP); in main() 125 test_connect(clt_sk, &svr_loop.sa, sizeof(svr_loop)); in main() 130 error = getsockname(clt_sk, (struct sockaddr *)&clt_local_addr, &len); in main() 140 error = getpeername(clt_sk, (struct sockaddr *)&clt_peer_addr, &len); in main() 230 error = getsockname(clt_sk, (struct sockaddr *)-1, &len); in main() 265 error = getpeername(clt_sk, (struct sockaddr *)-1, &len); in main() 272 close(clt_sk); in main()
|