diff options
| author | Ian Wisbon <ian.wisbon@timesys.com> | 2011-02-15 15:53:51 -0500 |
|---|---|---|
| committer | Ian Wisbon <ian.wisbon@timesys.com> | 2011-02-15 15:53:51 -0500 |
| commit | dfdbf3f6e2d279f2a46ed95614cb4bf07657394d (patch) | |
| tree | 2cc05669c5d3e47f7d4b28e31076b6dc6e771f36 /drivers/net/tun.c | |
| parent | effff5718c380983788fe6c380671c18e15ac7c2 (diff) | |
Digi del-5.6 Complete2.6.31-digi-201102151558
Diffstat (limited to 'drivers/net/tun.c')
| -rw-r--r-- | drivers/net/tun.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/net/tun.c b/drivers/net/tun.c index 42b6c6319bc2..156f59b25191 100644 --- a/drivers/net/tun.c +++ b/drivers/net/tun.c @@ -943,8 +943,6 @@ static int tun_set_iff(struct net *net, struct file *file, struct ifreq *ifr) char *name; unsigned long flags = 0; - err = -EINVAL; - if (!capable(CAP_NET_ADMIN)) return -EPERM; @@ -958,7 +956,7 @@ static int tun_set_iff(struct net *net, struct file *file, struct ifreq *ifr) flags |= TUN_TAP_DEV; name = "tap%d"; } else - goto failed; + return -EINVAL; if (*ifr->ifr_name) name = ifr->ifr_name; |
