[media] media: vb2: fix queueing of userptr buffers with null buffer pointer
authorMarek Szyprowski <m.szyprowski@samsung.com>
Wed, 16 Nov 2011 18:09:40 +0000 (15:09 -0300)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Fri, 30 Dec 2011 18:03:46 +0000 (16:03 -0200)
commitf0b7c7fc6f15e823cb4a5d225d9ef28b884ab6ec
treea460428bbaf613bc8e209e52fc13b2a6b713a673
parent54828d19f82be0d62e22fbd5a6354136c50a20eb
[media] media: vb2: fix queueing of userptr buffers with null buffer pointer

Heuristic that checks if the memory pointer has been changed lacked a check
if the pointer was actually provided by the userspace, what allowed one to
queue a NULL pointer which was accepted without further checking. This
patch fixes this issue.

Reported-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
CC: Pawel Osciak <pawel@osciak.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
drivers/media/video/videobuf2-core.c