Skip to content

Commit

Permalink
Phonet: correct sendmsg() error code from sock_alloc_send_skb()
Browse files Browse the repository at this point in the history
Signed-off-by: Rémi Denis-Courmont <remi.denis-courmont@nokia.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Rémi Denis-Courmont authored and David S. Miller committed Aug 31, 2010
1 parent 1a98214 commit 02ac326
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion net/phonet/pep.c
Original file line number Diff line number Diff line change
Expand Up @@ -876,7 +876,7 @@ static int pep_sendmsg(struct kiocb *iocb, struct sock *sk,
skb = sock_alloc_send_skb(sk, MAX_PNPIPE_HEADER + len,
flags & MSG_DONTWAIT, &err);
if (!skb)
return -ENOBUFS;
return err;

skb_reserve(skb, MAX_PHONET_HEADER + 3);
err = memcpy_fromiovec(skb_put(skb, len), msg->msg_iov, len);
Expand Down

0 comments on commit 02ac326

Please sign in to comment.