Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 310751
b: refs/heads/master
c: 4399a4d
h: refs/heads/master
i:
  310749: d5302e1
  310747: af34d44
  310743: 96447ed
  310735: 93f4f42
  310719: 7d94017
v: v3
  • Loading branch information
Eric Dumazet authored and David S. Miller committed Jun 8, 2012
1 parent 0403ae4 commit 45bdc50
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 6a2b28ef036ab5c66fdc606fe97d9e5cb34ea409
refs/heads/master: 4399a4df98a63e30fd16e9d0cecc46ea92269e8f
9 changes: 6 additions & 3 deletions trunk/net/l2tp/l2tp_ip.c
Original file line number Diff line number Diff line change
Expand Up @@ -464,17 +464,20 @@ static int l2tp_ip_sendmsg(struct kiocb *iocb, struct sock *sk, struct msghdr *m
sk->sk_bound_dev_if);
if (IS_ERR(rt))
goto no_route;
if (connected)
if (connected) {
sk_setup_caps(sk, &rt->dst);
else
dst_release(&rt->dst); /* safe since we hold rcu_read_lock */
} else {
skb_dst_set(skb, &rt->dst);
goto xmit;
}
}

/* We dont need to clone dst here, it is guaranteed to not disappear.
* __dev_xmit_skb() might force a refcount if needed.
*/
skb_dst_set_noref(skb, &rt->dst);

xmit:
/* Queue the packet to IP for output */
rc = ip_queue_xmit(skb, &inet->cork.fl);
rcu_read_unlock();
Expand Down

0 comments on commit 45bdc50

Please sign in to comment.