Commit 0980c1e3 authored by Eric Dumazet's avatar Eric Dumazet Committed by David S. Miller

tcp: use C99 initializers in new_state[]

Signed-off-by: default avatarEric Dumazet <edumazet@google.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 80f03e27
...@@ -1913,18 +1913,19 @@ EXPORT_SYMBOL_GPL(tcp_set_state); ...@@ -1913,18 +1913,19 @@ EXPORT_SYMBOL_GPL(tcp_set_state);
static const unsigned char new_state[16] = { static const unsigned char new_state[16] = {
/* current state: new state: action: */ /* current state: new state: action: */
/* (Invalid) */ TCP_CLOSE, [0 /* (Invalid) */] = TCP_CLOSE,
/* TCP_ESTABLISHED */ TCP_FIN_WAIT1 | TCP_ACTION_FIN, [TCP_ESTABLISHED] = TCP_FIN_WAIT1 | TCP_ACTION_FIN,
/* TCP_SYN_SENT */ TCP_CLOSE, [TCP_SYN_SENT] = TCP_CLOSE,
/* TCP_SYN_RECV */ TCP_FIN_WAIT1 | TCP_ACTION_FIN, [TCP_SYN_RECV] = TCP_FIN_WAIT1 | TCP_ACTION_FIN,
/* TCP_FIN_WAIT1 */ TCP_FIN_WAIT1, [TCP_FIN_WAIT1] = TCP_FIN_WAIT1,
/* TCP_FIN_WAIT2 */ TCP_FIN_WAIT2, [TCP_FIN_WAIT2] = TCP_FIN_WAIT2,
/* TCP_TIME_WAIT */ TCP_CLOSE, [TCP_TIME_WAIT] = TCP_CLOSE,
/* TCP_CLOSE */ TCP_CLOSE, [TCP_CLOSE] = TCP_CLOSE,
/* TCP_CLOSE_WAIT */ TCP_LAST_ACK | TCP_ACTION_FIN, [TCP_CLOSE_WAIT] = TCP_LAST_ACK | TCP_ACTION_FIN,
/* TCP_LAST_ACK */ TCP_LAST_ACK, [TCP_LAST_ACK] = TCP_LAST_ACK,
/* TCP_LISTEN */ TCP_CLOSE, [TCP_LISTEN] = TCP_CLOSE,
/* TCP_CLOSING */ TCP_CLOSING, [TCP_CLOSING] = TCP_CLOSING,
[TCP_NEW_SYN_RECV] = TCP_CLOSE, /* should not happen ! */
}; };
static int tcp_close_state(struct sock *sk) static int tcp_close_state(struct sock *sk)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment