13595725ca23b2d42d070af27ce89c982320edc9
[openwrt.git] / target / linux / generic / patches-2.6.37 / 280-solos_dont_null_deref.patch
1 --- a/drivers/atm/solos-pci.c
2 +++ b/drivers/atm/solos-pci.c
3 @@ -866,8 +866,9 @@ static int popen(struct atm_vcc *vcc)
4 }
5
6 skb = alloc_skb(sizeof(*header), GFP_ATOMIC);
7 - if (!skb && net_ratelimit()) {
8 - dev_warn(&card->dev->dev, "Failed to allocate sk_buff in popen()\n");
9 + if (!skb) {
10 + if (net_ratelimit())
11 + dev_warn(&card->dev->dev, "Failed to allocate sk_buff in popen()\n");
12 return -ENOMEM;
13 }
14 header = (void *)skb_put(skb, sizeof(*header));
This page took 0.038474 seconds and 3 git commands to generate.