Skip to content

Commit

Permalink
V4L/DVB (4740): Fixed an if-block to avoid floating with debug-messages
Browse files Browse the repository at this point in the history
The dbgarg() macro in videodev.c contains some printk() statements
where only the first one is influenced by an if-statement. This causes
floating with debug-messages which is fixed by this patch by adding a
'{ ... }' pair.

Signed-off-by: Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
  • Loading branch information
Enrico Scholz authored and Mauro Carvalho Chehab committed Oct 14, 2006
1 parent fc2fa31 commit 474ce78
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions drivers/media/video/videodev.c
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,11 @@
*/

#define dbgarg(cmd, fmt, arg...) \
if (vfd->debug & V4L2_DEBUG_IOCTL_ARG) \
if (vfd->debug & V4L2_DEBUG_IOCTL_ARG) { \
printk (KERN_DEBUG "%s: ", vfd->name); \
v4l_printk_ioctl(cmd); \
printk (KERN_DEBUG "%s: " fmt, vfd->name, ## arg);
printk (KERN_DEBUG "%s: " fmt, vfd->name, ## arg); \
}

#define dbgarg2(fmt, arg...) \
if (vfd->debug & V4L2_DEBUG_IOCTL_ARG) \
Expand Down

0 comments on commit 474ce78

Please sign in to comment.