mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-09-30 14:19:16 +00:00
wanmain: comparing array with NULL
gcc really should warn about these ! Signed-off-by: Alan Cox <alan@linux.intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
c66b9b7d36
commit
8b72ff6484
1 changed files with 21 additions and 26 deletions
|
@ -602,10 +602,6 @@ static int wanrouter_device_new_if(struct wan_device *wandev,
|
||||||
* successfully, add it to the interface list.
|
* successfully, add it to the interface list.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
if (dev->name == NULL) {
|
|
||||||
err = -EINVAL;
|
|
||||||
} else {
|
|
||||||
|
|
||||||
#ifdef WANDEBUG
|
#ifdef WANDEBUG
|
||||||
printk(KERN_INFO "%s: registering interface %s...\n",
|
printk(KERN_INFO "%s: registering interface %s...\n",
|
||||||
wanrouter_modname, dev->name);
|
wanrouter_modname, dev->name);
|
||||||
|
@ -632,7 +628,6 @@ static int wanrouter_device_new_if(struct wan_device *wandev,
|
||||||
err = 0; /* done !!! */
|
err = 0; /* done !!! */
|
||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
if (wandev->del_if)
|
if (wandev->del_if)
|
||||||
wandev->del_if(wandev, dev);
|
wandev->del_if(wandev, dev);
|
||||||
free_netdev(dev);
|
free_netdev(dev);
|
||||||
|
|
Loading…
Reference in a new issue