diff options
author | Colin Ian King <colin.king@canonical.com> | 2017-09-29 21:51:23 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2017-10-01 05:12:45 +0200 |
commit | 075cfdd659cb1e86f948f11ba577f27706f0756e (patch) | |
tree | 4429d7118de8d3454b5320ed5bc5a98bbbae475b /net/dsa/dsa_priv.h | |
parent | hv_netvsc: report stop_queue and wake_queue (diff) | |
download | linux-075cfdd659cb1e86f948f11ba577f27706f0756e.tar.xz linux-075cfdd659cb1e86f948f11ba577f27706f0756e.zip |
net: hns3: fix null pointer dereference before null check
pointer ndev is being dereferenced with the call to netif_running
before it is being null checked. Re-order the code to only dereference
ndev after it has been null checked.
Detected by CoverityScan, CID#1457206 ("Dereference before null check")
Fixes: 9df8f79a4d29 ("net: hns3: Add DCB support when interacting with network stack")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/dsa/dsa_priv.h')
0 files changed, 0 insertions, 0 deletions