linux-stable/drivers/media/pci/cx88
Ezequiel Garcia b52377475a [media] cx88: Replace memcpy with struct assignment
This kind of memcpy() is error-prone. Its replacement with a struct
assignment is prefered because it's type-safe and much easier to read.
Found by coccinelle. Hand patched and reviewed.
Tested by compilation only.
A simplified version of the semantic match that finds this problem is as
follows: (http://coccinelle.lip6.fr/)
// <smpl>
@@
identifier struct_name;
struct struct_name to;
struct struct_name from;
expression E;
@@
-memcpy(&(to), &(from), E);
+to = from;
// </smpl>

Signed-off-by: Peter Senna Tschudin <peter.senna@gmail.com>
Signed-off-by: Ezequiel Garcia <elezegarcia@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2012-12-27 19:01:51 -02:00
..
cx88-alsa.c [media] cx88: get rid of a warning at dprintk() macro 2012-10-28 07:38:41 -02:00
cx88-blackbird.c [media] cx88: get rid of a warning at dprintk() macro 2012-10-28 07:38:41 -02:00
cx88-cards.c [media] cx88: Replace memcpy with struct assignment 2012-12-27 19:01:51 -02:00
cx88-core.c [media] v4l: Convert drivers to use monotonic timestamps 2012-12-21 10:56:43 -02:00
cx88-dsp.c
cx88-dvb.c
cx88-i2c.c [media] cx88: Replace memcpy with struct assignment 2012-12-27 19:01:51 -02:00
cx88-input.c [media] rc-core: add separate defines for protocol bitmaps and numbers 2012-10-27 11:49:51 -02:00
cx88-mpeg.c [media] cx88: get rid of a warning at dprintk() macro 2012-10-28 07:38:41 -02:00
cx88-reg.h
cx88-tvaudio.c
cx88-vbi.c
cx88-video.c
cx88-vp3054-i2c.c [media] cx88: Replace memcpy with struct assignment 2012-12-27 19:01:51 -02:00
cx88-vp3054-i2c.h
cx88.h [media] cx88: reorder inline to prevent a gcc warning 2012-10-28 07:38:40 -02:00
Kconfig
Makefile