Patch "ax25: Fix segfault after sock connection timeout" has been added to the 4.4-stable tree
Subsystems (2)
This is a note to let you know that I've just added the patch titled
ax25: Fix segfault after sock connection timeout
to the 4.4-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary
The filename of the patch is:
ax25-fix-segfault-after-sock-connection-timeout.patch
and it can be found in the queue-4.4 subdirectory.
If you, or anyone else, feels it should not be added to the stable tree, please let <[email protected]> know about it.
Quoted 1 line
From foo@baz Wed Feb 1 08:49:51 CET 2017
From: Basil Gunn <[email protected]>
Date: Sat, 14 Jan 2017 12:18:55 -0800
Subject: ax25: Fix segfault after sock connection timeout
From: Basil Gunn <[email protected]>
[ Upstream commit 8a367e74c0120ef68c8c70d5a025648c96626dff ]
The ax.25 socket connection timed out & the sock struct has been previously taken down ie. sock struct is now a NULL pointer. Checking the sock_flag causes the segfault. Check if the socket struct pointer is NULL before checking sock_flag. This segfault is seen in timed out netrom connections.
Please submit to -stable.
--- net/ax25/ax25_subr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
net/ax25/ax25_subr.c +1 -1
@@ -264,7 +264,7 @@ void ax25_disconnect(ax25_cb *ax25, int {ax25_clear_queues (ax25); -if (!sock_flag (ax25->sk,SOCK_DESTROY )) +if (!ax25->sk || !sock_flag (ax25->sk,SOCK_DESTROY ))ax25_stop_heartbeat (ax25);ax25_stop_t1timer (ax25);ax25_stop_t2timer (ax25);
Patches currently in stable-queue which might be from [email protected] are
queue-4.4/ax25-fix-segfault-after-sock-connection-timeout.patch