Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ebf28551 authored by Surajit Podder's avatar Surajit Podder Committed by TARKZiM
Browse files

media: v4l2-compat-ioctl32: memset stack union in compat ioctl



memset karg in do_video_ioctl to ensure that stack memory is
not copied to user memory.

Change-Id: Ib892f8cabff1e0076c670496ee6353d00afdf85e
Signed-off-by: default avatarSurajit Podder <spodder@codeaurora.org>
Signed-off-by: default avatarSanjay Singh <sisanj@codeaurora.org>
parent 263e794b
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -847,6 +847,7 @@ static long do_video_ioctl(struct file *file, unsigned int cmd, unsigned long ar
	int compatible_arg = 1;
	long err = 0;

	memset(&karg, 0, sizeof(karg));
	/* First, convert the command. */
	switch (cmd) {
	case VIDIOC_G_FMT32: cmd = VIDIOC_G_FMT; break;