ia64/xen-unstable

changeset 5266:5bb481c21157

bitkeeper revision 1.1632 (429ebf12k6wKnt6NCp_ccTvyXrINWg)

skb_copy_bits() can return an err, so have netif_be_start_xmit()
crash informatively.
Signed-off-by: Nivedita Singhvi <niv@us.ibm.com>
author kaf24@firebug.cl.cam.ac.uk
date Thu Jun 02 08:10:58 2005 +0000 (2005-06-02)
parents d8410197d991
children 6c89d5f8c629
files linux-2.6.11-xen-sparse/drivers/xen/netback/netback.c
line diff
     1.1 --- a/linux-2.6.11-xen-sparse/drivers/xen/netback/netback.c	Thu Jun 02 07:56:31 2005 +0000
     1.2 +++ b/linux-2.6.11-xen-sparse/drivers/xen/netback/netback.c	Thu Jun 02 08:10:58 2005 +0000
     1.3 @@ -153,7 +153,8 @@ int netif_be_start_xmit(struct sk_buff *
     1.4              goto drop;
     1.5          skb_reserve(nskb, hlen);
     1.6          __skb_put(nskb, skb->len);
     1.7 -        (void)skb_copy_bits(skb, -hlen, nskb->data - hlen, skb->len + hlen);
     1.8 +        if (skb_copy_bits(skb, -hlen, nskb->data - hlen, skb->len + hlen))
     1.9 +            BUG();
    1.10          nskb->dev = skb->dev;
    1.11          nskb->proto_csum_valid = skb->proto_csum_valid;
    1.12          dev_kfree_skb(skb);