Skip to content
Snippets Groups Projects
Commit 7ed25867 authored by Wang YanQing's avatar Wang YanQing Committed by Florian Tobias Schandinat
Browse files

video:uvesafb: check the return value of kzalloc


Michal maybe forgot it merely, we should add code
to check the return value of kzalloc to make the
code more robust.

Signed-off-by: default avatarWang YanQing <udknight@gmail.com>
Signed-off-by: default avatarFlorian Tobias Schandinat <FlorianSchandinat@gmx.de>
parent bada5537
No related branches found
No related tags found
No related merge requests found
......@@ -659,6 +659,8 @@ static int __devinit uvesafb_vbe_getedid(struct uvesafb_ktask *task,
task->t.flags = TF_BUF_RET | TF_BUF_ESDI;
task->t.buf_len = EDID_LENGTH;
task->buf = kzalloc(EDID_LENGTH, GFP_KERNEL);
if (!task->buf)
return -ENOMEM;
err = uvesafb_exec(task);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment