aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net
diff options
context:
space:
mode:
authorAlexander Beregalov <a.beregalov@gmail.com>2009-04-23 11:31:38 -0400
committerDavid S. Miller <davem@davemloft.net>2009-04-27 06:02:46 -0400
commit4e204c1000561ddb1a62a9df857cb0457dd868a7 (patch)
tree77bd131db970bd2f3b0cf985978dabd2c961d15c /drivers/net
parent41f8910040639eb106b1a5b5301aab79ecde4940 (diff)
vxge: fix possible NULL dereference in vxge-traffic.c
If vpath is NULL then hldev is NULL also. Signed-off-by: Alexander Beregalov <a.beregalov@gmail.com> Acked-by: Ram Vepa <ram.vepa@neterion.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net')
-rw-r--r--drivers/net/vxge/vxge-traffic.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/vxge/vxge-traffic.c b/drivers/net/vxge/vxge-traffic.c
index 7be0ae10d69b..506625b180ac 100644
--- a/drivers/net/vxge/vxge-traffic.c
+++ b/drivers/net/vxge/vxge-traffic.c
@@ -1923,7 +1923,7 @@ enum vxge_hw_status __vxge_hw_vpath_alarm_process(
1923 if (vpath == NULL) { 1923 if (vpath == NULL) {
1924 alarm_event = VXGE_HW_SET_LEVEL(VXGE_HW_EVENT_UNKNOWN, 1924 alarm_event = VXGE_HW_SET_LEVEL(VXGE_HW_EVENT_UNKNOWN,
1925 alarm_event); 1925 alarm_event);
1926 goto out; 1926 goto out2;
1927 } 1927 }
1928 1928
1929 hldev = vpath->hldev; 1929 hldev = vpath->hldev;
@@ -2161,7 +2161,7 @@ enum vxge_hw_status __vxge_hw_vpath_alarm_process(
2161 } 2161 }
2162out: 2162out:
2163 hldev->stats.sw_dev_err_stats.vpath_alarms++; 2163 hldev->stats.sw_dev_err_stats.vpath_alarms++;
2164 2164out2:
2165 if ((alarm_event == VXGE_HW_EVENT_ALARM_CLEARED) || 2165 if ((alarm_event == VXGE_HW_EVENT_ALARM_CLEARED) ||
2166 (alarm_event == VXGE_HW_EVENT_UNKNOWN)) 2166 (alarm_event == VXGE_HW_EVENT_UNKNOWN))
2167 return VXGE_HW_OK; 2167 return VXGE_HW_OK;