diff options
author | Rich Lane <rlane@bigswitch.com> | 2013-02-08 12:30:23 -0500 |
---|---|---|
committer | Jesse Gross <jesse@nicira.com> | 2013-02-22 20:01:49 -0500 |
commit | 734907e82d21a75a514b80164185427a832a00c0 (patch) | |
tree | 6b8dbf9a592689862464581e1f70c21b1b0c0b52 | |
parent | 19f949f52599ba7c3f67a5897ac6be14bfcb1200 (diff) |
openvswitch: Fix ovs_vport_cmd_del return value on success
If the pointer does not represent an error then the PTR_ERR macro may still
return a nonzero value. The fix is the same as in ovs_vport_cmd_set.
Signed-off-by: Rich Lane <rlane@bigswitch.com>
Signed-off-by: Jesse Gross <jesse@nicira.com>
-rw-r--r-- | net/openvswitch/datapath.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/net/openvswitch/datapath.c b/net/openvswitch/datapath.c index f996db343247..5e275b903f3c 100644 --- a/net/openvswitch/datapath.c +++ b/net/openvswitch/datapath.c | |||
@@ -1772,6 +1772,7 @@ static int ovs_vport_cmd_del(struct sk_buff *skb, struct genl_info *info) | |||
1772 | if (IS_ERR(reply)) | 1772 | if (IS_ERR(reply)) |
1773 | goto exit_unlock; | 1773 | goto exit_unlock; |
1774 | 1774 | ||
1775 | err = 0; | ||
1775 | ovs_dp_detach_port(vport); | 1776 | ovs_dp_detach_port(vport); |
1776 | 1777 | ||
1777 | genl_notify(reply, genl_info_net(info), info->snd_portid, | 1778 | genl_notify(reply, genl_info_net(info), info->snd_portid, |