From 326a8ef0a28ff3ff5bfe5452dcf8295d6c849223 Mon Sep 17 00:00:00 2001 From: YAMAMOTO Takashi Date: Tue, 29 Jun 2021 19:44:26 +0900 Subject: [PATCH] tcp_close_disconnect: don't nullify sndcb It isn't necessary and I plan to use the value later in the close processing. --- net/tcp/tcp_close.c | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/net/tcp/tcp_close.c b/net/tcp/tcp_close.c index bd421c9ea19..2998d0d8624 100644 --- a/net/tcp/tcp_close.c +++ b/net/tcp/tcp_close.c @@ -262,16 +262,6 @@ static inline int tcp_close_disconnect(FAR struct socket *psock) } #endif -#ifdef CONFIG_NET_TCP_WRITE_BUFFERS - /* If we have a semi-permanent write buffer callback in place, then - * is needs to be be nullified. - * - * Note: the callback will be freed by tcp_free. - */ - - psock->s_sndcb = NULL; -#endif - /* Check for the case where the host beat us and disconnected first */ if (conn->tcpstateflags == TCP_ESTABLISHED &&