linux/net/dccp
Gerrit Renker 48816322ad dccp: Empty the write queue when disconnecting
dccp_disconnect() can be called due to several reasons:

 1. when the connection setup failed (inet_stream_connect());
 2. when shutting down (inet_shutdown(), inet_csk_listen_stop());
 3. when aborting the connection (dccp_close() with 0 linger time).

In case (1) the write queue is empty. This patch empties the write queue,
if in case (2) or (3) it was not yet empty.

This avoids triggering the write-queue BUG_TRAP in sk_stream_kill_queues()
later on.

It also seems natural to do: when breaking an association, to delete all
packets that were originally intended for the soon-disconnected end (compare
with call to tcp_write_queue_purge in tcp_disconnect()).

Signed-off-by: Gerrit Renker <gerrit@erg.abdn.ac.uk>
2008-09-04 07:45:25 +02:00
..
ccids dccp ccid-3: Length of loss intervals 2008-07-13 11:51:40 +01:00
ackvec.c dccp: Fix sparse warnings 2008-06-11 11:19:09 +01:00
ackvec.h [ACKVEC]: Reduce length of identifiers 2008-01-28 14:54:51 -08:00
ccid.c [CCID]: More informative registration 2008-01-28 14:57:58 -08:00
ccid.h [DCCP]: Introducing CCMPS 2008-01-28 14:57:59 -08:00
dccp.h tcp: Fix kernel panic when calling tcp_v(4/6)_md5_do_lookup 2008-08-06 23:50:04 -07:00
diag.c [INET]: Let inet_diag and friends autoload 2007-10-22 02:59:54 -07:00
feat.c dccp: return -EINVAL on invalid feature length 2008-05-05 13:50:24 -07:00
feat.h [DCCP]: Remove unused and redundant validation functions 2008-01-28 14:57:52 -08:00
input.c dccp: Always generate a Reset in response to option errors 2008-09-04 07:45:24 +02:00
ipv4.c dccp: Fix incorrect length check for ICMPv4 packets 2008-07-26 11:59:10 +01:00
ipv6.c dccp: Add check for truncated ICMPv6 DCCP error packets 2008-07-26 11:59:11 +01:00
ipv6.h Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
Kconfig [DCCP]: Promote CCID2 as default CCID 2008-01-28 14:54:46 -08:00
Makefile [DCCPv6]: Resolve conditional build problem 2006-12-02 21:22:28 -08:00
minisocks.c tcp: Fix kernel panic when calling tcp_v(4/6)_md5_do_lookup 2008-08-06 23:50:04 -07:00
options.c dccp: Fill in the Data fields for "Option Error" Resets 2008-09-04 07:45:25 +02:00
output.c dccp: Bug-Fix - AWL was never updated 2008-07-26 11:59:10 +01:00
probe.c dccp: Fix sparse warnings 2008-06-11 11:19:09 +01:00
proto.c dccp: Empty the write queue when disconnecting 2008-09-04 07:45:25 +02:00
sysctl.c [NET]: Simple ctl_table to ctl_path conversions. 2008-01-28 15:01:07 -08:00
timer.c dccp: Allow to distinguish original and retransmitted packets 2008-07-26 11:59:09 +01:00