mirror of
https://github.com/lwip-tcpip/lwip.git
synced 2025-01-15 22:49:16 +00:00
Try to fix compile error with clang (found by Erik's Travis-CI)
This commit is contained in:
parent
e8e853f2cb
commit
792224ead0
@ -545,12 +545,14 @@ accept_function(void *arg, struct tcp_pcb *newpcb, err_t err)
|
|||||||
static void
|
static void
|
||||||
pcb_new(struct api_msg *msg)
|
pcb_new(struct api_msg *msg)
|
||||||
{
|
{
|
||||||
enum lwip_ip_addr_type iptype;
|
enum lwip_ip_addr_type iptype = IPADDR_TYPE_V4;
|
||||||
|
|
||||||
LWIP_ASSERT("pcb_new: pcb already allocated", msg->conn->pcb.tcp == NULL);
|
LWIP_ASSERT("pcb_new: pcb already allocated", msg->conn->pcb.tcp == NULL);
|
||||||
|
|
||||||
/* IPv6: Dual-stack by default, unless netconn_set_ipv6only() is called */
|
/* IPv6: Dual-stack by default, unless netconn_set_ipv6only() is called */
|
||||||
iptype = NETCONNTYPE_ISIPV6(netconn_type(msg->conn))? IPADDR_TYPE_ANY : IPADDR_TYPE_V4;
|
if(NETCONNTYPE_ISIPV6(netconn_type(msg->conn))) {
|
||||||
|
iptype = IPADDR_TYPE_ANY;
|
||||||
|
}
|
||||||
|
|
||||||
/* Allocate a PCB for this connection */
|
/* Allocate a PCB for this connection */
|
||||||
switch(NETCONNTYPE_GROUP(msg->conn->type)) {
|
switch(NETCONNTYPE_GROUP(msg->conn->type)) {
|
||||||
|
Loading…
Reference in New Issue
Block a user