mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-08-27 19:29:37 +00:00
Staging: dream, fix buf overflow
In vfe_send_msg_no_payload there is a wrong struct vfe_message allocation. It allocates only sizeof(pointer to vfe_message) for a whole structure. Add a dereference to the sizeof to allocate sizeof(vfe_message). Signed-off-by: Jiri Slaby <jirislaby@gmail.com> Acked-by: Pavel Machek <pavel@ucw.cz> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This commit is contained in:
parent
58c6d6d1a6
commit
4d62691b60
1 changed files with 1 additions and 1 deletions
|
@ -818,7 +818,7 @@ static void vfe_send_msg_no_payload(enum VFE_MESSAGE_ID id)
|
|||
{
|
||||
struct vfe_message *msg;
|
||||
|
||||
msg = kzalloc(sizeof(msg), GFP_ATOMIC);
|
||||
msg = kzalloc(sizeof(*msg), GFP_ATOMIC);
|
||||
if (!msg)
|
||||
return;
|
||||
|
||||
|
|
Loading…
Reference in a new issue