Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 159022
b: refs/heads/master
c: 2e2fb4b
h: refs/heads/master
v: v3
  • Loading branch information
Rémi Denis-Courmont authored and David S. Miller committed Jul 24, 2009
1 parent 400a9aa commit 77d71ae
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 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: c1dc13e9d0bc35a8d85bf4238c48c1b627d48f35
refs/heads/master: 2e2fb4b33d62c742019774c5e6e47711a3d60505
7 changes: 6 additions & 1 deletion trunk/net/phonet/pep.c
Original file line number Diff line number Diff line change
Expand Up @@ -346,8 +346,10 @@ static int pipe_do_rcv(struct sock *sk, struct sk_buff *skb)
break;

case PNS_PEP_CTRL_REQ:
if (skb_queue_len(&pn->ctrlreq_queue) >= PNPIPE_CTRLREQ_MAX)
if (skb_queue_len(&pn->ctrlreq_queue) >= PNPIPE_CTRLREQ_MAX) {
atomic_inc(&sk->sk_drops);
break;
}
__skb_pull(skb, 4);
queue = &pn->ctrlreq_queue;
goto queue;
Expand All @@ -358,10 +360,13 @@ static int pipe_do_rcv(struct sock *sk, struct sk_buff *skb)
err = sock_queue_rcv_skb(sk, skb);
if (!err)
return 0;
if (err == -ENOMEM)
atomic_inc(&sk->sk_drops);
break;
}

if (pn->rx_credits == 0) {
atomic_inc(&sk->sk_drops);
err = -ENOBUFS;
break;
}
Expand Down

0 comments on commit 77d71ae

Please sign in to comment.