Commit d698f1c7 authored by Eric Sesterhenn's avatar Eric Sesterhenn Committed by Linus Torvalds

[PATCH] fix array overrun in drivers/char/mwave/mwavedd.c

this fixes coverity id #489.

Since the last element in the array is always ARRAY_SIZE-1 we have to check
for ipcnum >= ARRAY_SIZE()
Signed-off-by: default avatarEric Sesterhenn <>
Signed-off-by: default avatarAdrian Bunk <>
Signed-off-by: default avatarAndrew Morton <>
Signed-off-by: default avatarLinus Torvalds <>
parent 1ac3836c
......@@ -271,7 +271,7 @@ static int mwave_ioctl(struct inode *inode, struct file *file,
if (ipcnum > ARRAY_SIZE(pDrvData->IPCs)) {
if (ipcnum >= ARRAY_SIZE(pDrvData->IPCs)) {
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment