Lines Matching refs:optlen
151 #define LWIP_SOCKOPT_CHECK_OPTLEN(optlen, opttype) do { if ((optlen) < sizeof(opttype)) { return EI… argument
152 #define LWIP_SOCKOPT_CHECK_OPTLEN_CONN(sock, optlen, opttype) do { \ argument
153 LWIP_SOCKOPT_CHECK_OPTLEN(optlen, opttype); \
155 #define LWIP_SOCKOPT_CHECK_OPTLEN_CONN_PCB(sock, optlen, opttype) do { \ argument
156 LWIP_SOCKOPT_CHECK_OPTLEN(optlen, opttype); \
158 #define LWIP_SOCKOPT_CHECK_OPTLEN_CONN_PCB_TYPE(sock, optlen, opttype, netconntype) do { \ argument
159 LWIP_SOCKOPT_CHECK_OPTLEN_CONN_PCB(sock, optlen, opttype); \
321 static u8_t lwip_getsockopt_impl(int s, int level, int optname, void *optval, socklen_t *optlen);
322 …tic u8_t lwip_setsockopt_impl(int s, int level, int optname, const void *optval, socklen_t optlen);
1814 lwip_getsockopt(int s, int level, int optname, void *optval, socklen_t *optlen) in lwip_getsockopt() argument
1826 if ((NULL == optval) || (NULL == optlen)) { in lwip_getsockopt()
1834 err = lwip_getsockopt_impl(s, level, optname, optval, optlen); in lwip_getsockopt()
1841 if (*optlen > LWIP_SETGETSOCKOPT_MAXOPTLEN) { in lwip_getsockopt()
1851 LWIP_SETGETSOCKOPT_DATA_VAR_REF(data).optlen = *optlen; in lwip_getsockopt()
1870 *optlen = LWIP_SETGETSOCKOPT_DATA_VAR_REF(data).optlen; in lwip_getsockopt()
1873 LWIP_SETGETSOCKOPT_DATA_VAR_REF(data).optlen); in lwip_getsockopt()
1902 &data->optlen); in lwip_getsockopt_callback()
1912 lwip_getsockopt_impl(int s, int level, int optname, void *optval, socklen_t *optlen) in lwip_getsockopt_impl() argument
1928 LWIP_SOCKOPT_CHECK_OPTLEN_CONN_PCB(sock, *optlen, int); in lwip_getsockopt_impl()
1946 LWIP_SOCKOPT_CHECK_OPTLEN_CONN_PCB(sock, *optlen, int); in lwip_getsockopt_impl()
1953 LWIP_SOCKOPT_CHECK_OPTLEN_CONN(sock, *optlen, int); in lwip_getsockopt_impl()
1975 LWIP_SOCKOPT_CHECK_OPTLEN(*optlen, int); in lwip_getsockopt_impl()
1988 LWIP_SOCKOPT_CHECK_OPTLEN_CONN(sock, *optlen, LWIP_SO_SNDRCVTIMEO_OPTTYPE); in lwip_getsockopt_impl()
1994 LWIP_SOCKOPT_CHECK_OPTLEN_CONN(sock, *optlen, LWIP_SO_SNDRCVTIMEO_OPTTYPE); in lwip_getsockopt_impl()
2000 LWIP_SOCKOPT_CHECK_OPTLEN_CONN(sock, *optlen, int); in lwip_getsockopt_impl()
2009 LWIP_SOCKOPT_CHECK_OPTLEN_CONN(sock, *optlen, struct linger); in lwip_getsockopt_impl()
2023 LWIP_SOCKOPT_CHECK_OPTLEN_CONN_PCB_TYPE(sock, *optlen, int, NETCONN_UDP); in lwip_getsockopt_impl()
2045 LWIP_SOCKOPT_CHECK_OPTLEN_CONN_PCB(sock, *optlen, int); in lwip_getsockopt_impl()
2051 LWIP_SOCKOPT_CHECK_OPTLEN_CONN_PCB(sock, *optlen, int); in lwip_getsockopt_impl()
2058 LWIP_SOCKOPT_CHECK_OPTLEN_CONN_PCB(sock, *optlen, u8_t); in lwip_getsockopt_impl()
2067 LWIP_SOCKOPT_CHECK_OPTLEN_CONN_PCB(sock, *optlen, struct in_addr); in lwip_getsockopt_impl()
2076 LWIP_SOCKOPT_CHECK_OPTLEN_CONN_PCB(sock, *optlen, u8_t); in lwip_getsockopt_impl()
2098 LWIP_SOCKOPT_CHECK_OPTLEN_CONN_PCB_TYPE(sock, *optlen, int, NETCONN_TCP); in lwip_getsockopt_impl()
2145 LWIP_SOCKOPT_CHECK_OPTLEN_CONN(sock, *optlen, int); in lwip_getsockopt_impl()
2163 LWIP_SOCKOPT_CHECK_OPTLEN_CONN_PCB(sock, *optlen, int); in lwip_getsockopt_impl()
2192 LWIP_SOCKOPT_CHECK_OPTLEN_CONN_PCB_TYPE(sock, *optlen, int, NETCONN_RAW); in lwip_getsockopt_impl()
2220 lwip_setsockopt(int s, int level, int optname, const void *optval, socklen_t optlen) in lwip_setsockopt() argument
2240 err = lwip_setsockopt_impl(s, level, optname, optval, optlen); in lwip_setsockopt()
2247 if (optlen > LWIP_SETGETSOCKOPT_MAXOPTLEN) { in lwip_setsockopt()
2257 LWIP_SETGETSOCKOPT_DATA_VAR_REF(data).optlen = optlen; in lwip_setsockopt()
2259 MEMCPY(LWIP_SETGETSOCKOPT_DATA_VAR_REF(data).optval, optval, optlen); in lwip_setsockopt()
2303 data->optlen); in lwip_setsockopt_callback()
2313 lwip_setsockopt_impl(int s, int level, int optname, const void *optval, socklen_t optlen) in lwip_setsockopt_impl() argument
2335 LWIP_SOCKOPT_CHECK_OPTLEN_CONN_PCB(sock, optlen, int); in lwip_setsockopt_impl()
2350 LWIP_SOCKOPT_CHECK_OPTLEN_CONN(sock, optlen, LWIP_SO_SNDRCVTIMEO_OPTTYPE); in lwip_setsockopt_impl()
2356 LWIP_SOCKOPT_CHECK_OPTLEN_CONN(sock, optlen, LWIP_SO_SNDRCVTIMEO_OPTTYPE); in lwip_setsockopt_impl()
2362 LWIP_SOCKOPT_CHECK_OPTLEN_CONN(sock, optlen, int); in lwip_setsockopt_impl()
2370 LWIP_SOCKOPT_CHECK_OPTLEN_CONN(sock, optlen, struct linger); in lwip_setsockopt_impl()
2388 LWIP_SOCKOPT_CHECK_OPTLEN_CONN_PCB_TYPE(sock, optlen, int, NETCONN_UDP); in lwip_setsockopt_impl()
2414 LWIP_SOCKOPT_CHECK_OPTLEN_CONN_PCB(sock, optlen, int); in lwip_setsockopt_impl()
2420 LWIP_SOCKOPT_CHECK_OPTLEN_CONN_PCB(sock, optlen, int); in lwip_setsockopt_impl()
2427 LWIP_SOCKOPT_CHECK_OPTLEN_CONN_PCB_TYPE(sock, optlen, u8_t, NETCONN_UDP); in lwip_setsockopt_impl()
2433 LWIP_SOCKOPT_CHECK_OPTLEN_CONN_PCB_TYPE(sock, optlen, struct in_addr, NETCONN_UDP); in lwip_setsockopt_impl()
2439 LWIP_SOCKOPT_CHECK_OPTLEN_CONN_PCB_TYPE(sock, optlen, u8_t, NETCONN_UDP); in lwip_setsockopt_impl()
2457 LWIP_SOCKOPT_CHECK_OPTLEN_CONN_PCB_TYPE(sock, optlen, struct ip_mreq, NETCONN_UDP); in lwip_setsockopt_impl()
2490 LWIP_SOCKOPT_CHECK_OPTLEN_CONN_PCB_TYPE(sock, optlen, int, NETCONN_TCP); in lwip_setsockopt_impl()
2541 LWIP_SOCKOPT_CHECK_OPTLEN_CONN_PCB_TYPE(sock, optlen, int, NETCONN_TCP); in lwip_setsockopt_impl()
2563 LWIP_SOCKOPT_CHECK_OPTLEN_CONN_PCB(sock, optlen, int); in lwip_setsockopt_impl()
2608 LWIP_SOCKOPT_CHECK_OPTLEN_CONN_PCB_TYPE(sock, optlen, int, NETCONN_RAW); in lwip_setsockopt_impl()