yuezonghe | 824eb0c | 2024-06-27 02:32:26 -0700 | [diff] [blame] | 1 | |
| 2 | #ifndef SOCKET_HELPER_H |
| 3 | #define SOCKET_HELPER_H |
| 4 | |
| 5 | #include "headers.h" |
| 6 | |
| 7 | /* |
| 8 | typedef union |
| 9 | { |
| 10 | struct sockaddr_in sockaddr; |
| 11 | struct sockaddr_in6 sockaddr6; |
| 12 | } zperf_sockaddr_t; |
| 13 | */ |
| 14 | typedef struct sockaddr_in zping_sockaddr_t; |
| 15 | |
| 16 | void close_one_socket(int sock); |
| 17 | |
| 18 | void SockAddr_setHostname(const char* inHostname, zping_sockaddr_t *inSockAddr) ; |
| 19 | |
| 20 | int setsock_tcp_windowsize(int inSock, int inTCPWin, int inSend); |
| 21 | |
| 22 | void setsock_tcp_mss(int inSock, int inMSS); |
| 23 | |
| 24 | #endif |