diff options
author | Matthias Kaehlcke <mka@chromium.org> | 2017-07-25 11:36:25 -0700 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2019-02-27 10:07:01 +0100 |
commit | 64696ba9577f7742358cd7be42da2a4eb4877244 (patch) | |
tree | 2cbe271d4e672ea34907ae682189ec8657fe5369 /kernel | |
parent | 146558f0d27f299d607973574e33000f3c8aa87d (diff) |
netpoll: Fix device name check in netpoll_setup()
commit 0c3a8f8b8fabff4f3ad2dd7b95ae0e90cdd1aebb upstream.
Apparently netpoll_setup() assumes that netpoll.dev_name is a pointer
when checking if the device name is set:
if (np->dev_name) {
...
However the field is a character array, therefore the condition always
yields true. Check instead whether the first byte of the array has a
non-zero value.
Signed-off-by: Matthias Kaehlcke <mka@chromium.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Nathan Chancellor <natechancellor@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'kernel')
0 files changed, 0 insertions, 0 deletions