Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 300607
b: refs/heads/master
c: e1e420c
h: refs/heads/master
i:
  300605: 27eded1
  300603: 4bdd991
  300599: 7b5e5d6
  300591: 901e2b8
  300575: 04ee774
  300543: 2e7f62b
v: v3
  • Loading branch information
Shuah Khan authored and David S. Miller committed Apr 12, 2012
1 parent ab52d72 commit 2c87fea
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 1caf09df78a1b40604f200f419b08819e139b858
refs/heads/master: e1e420c71b53829c661123a21b14a42d821e5e7f
5 changes: 2 additions & 3 deletions trunk/net/core/net-sysfs.c
Original file line number Diff line number Diff line change
Expand Up @@ -74,15 +74,14 @@ static ssize_t netdev_store(struct device *dev, struct device_attribute *attr,
int (*set)(struct net_device *, unsigned long))
{
struct net_device *net = to_net_dev(dev);
char *endp;
unsigned long new;
int ret = -EINVAL;

if (!capable(CAP_NET_ADMIN))
return -EPERM;

new = simple_strtoul(buf, &endp, 0);
if (endp == buf)
ret = kstrtoul(buf, 0, &new);
if (ret)
goto err;

if (!rtnl_trylock())
Expand Down

0 comments on commit 2c87fea

Please sign in to comment.