diff options
author | Alexander Shiyan <shc_work@mail.ru> | 2014-02-25 23:41:14 -0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2016-09-11 09:59:58 +0200 |
commit | a6e226c25157082a043cce63d14ecab68fdcc433 (patch) | |
tree | 582f5f3cbb0d3340b2c8e658a64f15e0522bb90e | |
parent | 7ae8ffd384be9159cf057affd17caf2a687f493f (diff) | |
download | linux-stable-a6e226c25157082a043cce63d14ecab68fdcc433.tar.gz linux-stable-a6e226c25157082a043cce63d14ecab68fdcc433.tar.bz2 linux-stable-a6e226c25157082a043cce63d14ecab68fdcc433.zip |
stb6100: fix buffer length check in stb6100_write_reg_range()
commit 7e6bd12fb77b0067df13fb3ba3fadbdff2945396 upstream.
We are checking sizeof() the wrong variable!
Signed-off-by: Alexander Shiyan <shc_work@mail.ru>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
Cc: Willy Tarreau <w@1wt.eu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r-- | drivers/media/dvb-frontends/stb6100.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/media/dvb-frontends/stb6100.c b/drivers/media/dvb-frontends/stb6100.c index cea175d19890..4ef8a5c7003e 100644 --- a/drivers/media/dvb-frontends/stb6100.c +++ b/drivers/media/dvb-frontends/stb6100.c @@ -193,7 +193,7 @@ static int stb6100_write_reg_range(struct stb6100_state *state, u8 buf[], int st .len = len + 1 }; - if (1 + len > sizeof(buf)) { + if (1 + len > sizeof(cmdbuf)) { printk(KERN_WARNING "%s: i2c wr: len=%d is too big!\n", KBUILD_MODNAME, len); |