]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/isdn/capi/kcapi.c
pci: hotplug: pciehp: fix error code path in hpc_power_off_slot
[linux-2.6-omap-h63xx.git] / drivers / isdn / capi / kcapi.c
index 9f73bc2727c29f8d8fe393b9fbd8faa37af2218a..f55531869313f2422705c79910568982dd476a2e 100644 (file)
@@ -821,6 +821,8 @@ static int old_capi_manufacturer(unsigned int cmd, void __user *data)
                                return -EFAULT;
                }
                card = get_capi_ctr_by_nr(ldef.contr);
+               if (!card)
+                       return -EINVAL;
                card = capi_ctr_get(card);
                if (!card)
                        return -ESRCH;