diff options
author | Thibaut VARÈNE <hacks@slashdirt.org> | 2020-08-18 11:57:31 +0200 |
---|---|---|
committer | Adrian Schmutzler <freifunk@adrianschmutzler.de> | 2020-08-18 18:22:33 +0200 |
commit | d8ecaef409517c3c09381bee648e7beb35ae4329 (patch) | |
tree | c127909387e103b9f723c1c270ea61abfd7880c3 /target | |
parent | 008db6b970613d291b245d95734e3e42b5455f6c (diff) | |
download | upstream-d8ecaef409517c3c09381bee648e7beb35ae4329.tar.gz upstream-d8ecaef409517c3c09381bee648e7beb35ae4329.tar.bz2 upstream-d8ecaef409517c3c09381bee648e7beb35ae4329.zip |
generic: platform/mikrotik: fix incorrect test
The test is meant to check the result of the preceding kmalloc()
Signed-off-by: Thibaut VARÈNE <hacks@slashdirt.org>
(cherry picked from commit d0498872ff71a79f0676cfc6b6b547c499bff712)
Diffstat (limited to 'target')
-rw-r--r-- | target/linux/generic/files/drivers/platform/mikrotik/rb_hardconfig.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/target/linux/generic/files/drivers/platform/mikrotik/rb_hardconfig.c b/target/linux/generic/files/drivers/platform/mikrotik/rb_hardconfig.c index 06530f7caa..46dc476003 100644 --- a/target/linux/generic/files/drivers/platform/mikrotik/rb_hardconfig.c +++ b/target/linux/generic/files/drivers/platform/mikrotik/rb_hardconfig.c @@ -495,7 +495,7 @@ static int hc_wlan_data_unpack_lzor(const u8 *inbuf, size_t inlen, /* Temporary buffer same size as the outbuf */ templen = *outlen; tempbuf = kmalloc(templen, GFP_KERNEL); - if (!outbuf) + if (!tempbuf) return -ENOMEM; /* Concatenate into the outbuf */ |