提交 7e6bd12f 编写于 作者: A Alexander Shiyan 提交者: Mauro Carvalho Chehab

[media] stb6100: fix buffer length check in stb6100_write_reg_range()

We are checking sizeof() the wrong variable!
Signed-off-by: NAlexander Shiyan <shc_work@mail.ru>
Signed-off-by: NMichael Krufky <mkrufky@linuxtv.org>
Signed-off-by: NMauro Carvalho Chehab <m.chehab@samsung.com>
上级 c6aa852a
...@@ -193,7 +193,7 @@ static int stb6100_write_reg_range(struct stb6100_state *state, u8 buf[], int st ...@@ -193,7 +193,7 @@ static int stb6100_write_reg_range(struct stb6100_state *state, u8 buf[], int st
.len = len + 1 .len = len + 1
}; };
if (1 + len > sizeof(buf)) { if (1 + len > sizeof(cmdbuf)) {
printk(KERN_WARNING printk(KERN_WARNING
"%s: i2c wr: len=%d is too big!\n", "%s: i2c wr: len=%d is too big!\n",
KBUILD_MODNAME, len); KBUILD_MODNAME, len);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册