diff options
author | Trond Myklebust <Trond.Myklebust@netapp.com> | 2005-10-27 19:12:49 -0400 |
---|---|---|
committer | Trond Myklebust <Trond.Myklebust@netapp.com> | 2005-10-27 19:12:49 -0400 |
commit | 4c2cb58c552a34744979a99ccf01762d5eb7e288 (patch) | |
tree | fd35360eb0cb08b07f3a5f4bdf1ebd90a769311d /net/dccp/output.c | |
parent | 34123da66e613602de5a886b05c875b6a91b8ed2 (diff) | |
parent | 72ab373a5688a78cbdaf3bf96012e597d5399bb7 (diff) |
Merge /home/trondmy/scm/kernel/git/torvalds/linux-2.6
Diffstat (limited to 'net/dccp/output.c')
-rw-r--r-- | net/dccp/output.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/net/dccp/output.c b/net/dccp/output.c index 4786bdcddcc9..29250749f16f 100644 --- a/net/dccp/output.c +++ b/net/dccp/output.c @@ -62,10 +62,8 @@ int dccp_transmit_skb(struct sock *sk, struct sk_buff *skb) skb->h.raw = skb_push(skb, dccp_header_size); dh = dccp_hdr(skb); - /* - * Data packets are not cloned as they are never retransmitted - */ - if (skb_cloned(skb)) + + if (!skb->sk) skb_set_owner_w(skb, sk); /* Build DCCP header and checksum it. */ @@ -102,6 +100,7 @@ int dccp_transmit_skb(struct sock *sk, struct sk_buff *skb) DCCP_INC_STATS(DCCP_MIB_OUTSEGS); + memset(&(IPCB(skb)->opt), 0, sizeof(IPCB(skb)->opt)); err = ip_queue_xmit(skb, 0); if (err <= 0) return err; @@ -243,7 +242,8 @@ int dccp_write_xmit(struct sock *sk, struct sk_buff *skb, long *timeo) err = dccp_transmit_skb(sk, skb); ccid_hc_tx_packet_sent(dp->dccps_hc_tx_ccid, sk, 0, len); - } + } else + kfree_skb(skb); return err; } |