You've already forked linux-apfs
mirror of
https://github.com/linux-apfs/linux-apfs.git
synced 2026-05-01 15:00:59 -07:00
V4L/DVB: omap24xxcam: potential buffer overflow
The previous loop goes until last == VIDEO_MAX_FRAME, so this could potentially go one past the end of the loop. Signed-off-by: Dan Carpenter <error27@gmail.com> Acked-by: Sakari Ailus <sakari.ailus@maxwell.research.nokia.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
This commit is contained in:
committed by
Mauro Carvalho Chehab
parent
722154e4ca
commit
2132deff69
@@ -1405,7 +1405,7 @@ static int omap24xxcam_mmap_buffers(struct file *file,
|
||||
}
|
||||
|
||||
size = 0;
|
||||
for (i = first; i <= last; i++) {
|
||||
for (i = first; i <= last && i < VIDEO_MAX_FRAME; i++) {
|
||||
struct videobuf_dmabuf *dma = videobuf_to_dma(vbq->bufs[i]);
|
||||
|
||||
for (j = 0; j < dma->sglen; j++) {
|
||||
|
||||
Reference in New Issue
Block a user