提交 479bc59d 编写于 作者: T Tomas Winkler 提交者: Greg Kroah-Hartman

staging: mei: fix possible usage of uninitialized variable

Fix warning: reported in http://marc.info/?l=linux-kernel&m=130812960402606&w=2

drivers/staging/mei/interrupt.c: warning: 'buffer' may be used uninitialized in this function:  => 198

It is a real issue and wrong path in execution is taken when
list is empty or (cl && _mei_irq_thread_state_ok(cl, mei_hdr))
evaluates to false
Signed-off-by: NTomas Winkler <tomas.winkler@intel.com>
Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
上级 0288c7c9
......@@ -195,7 +195,7 @@ static int mei_irq_thread_read_client_message(struct mei_io_list *complete_list,
{
struct mei_cl *cl;
struct mei_cl_cb *cb_pos = NULL, *cb_next = NULL;
unsigned char *buffer;
unsigned char *buffer = NULL;
dev_dbg(&dev->pdev->dev, "start client msg\n");
if (!(dev->read_list.status == 0 &&
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册