linux/drivers/media/pci/bt8xx
Ezequiel Garcia b4b1d04006 [media] bttv: 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:02:38 -02:00
..
bt848.h
bt878.c
bt878.h
bttv-audio-hook.c
bttv-audio-hook.h
bttv-cards.c
bttv-driver.c [media] v4l: Convert drivers to use monotonic timestamps 2012-12-21 10:56:43 -02:00
bttv-gpio.c
bttv-i2c.c [media] bttv: Replace memcpy with struct assignment 2012-12-27 19:02:38 -02:00
bttv-if.c
bttv-input.c
bttv-risc.c
bttv-vbi.c
bttv.h
bttvp.h
dst_ca.c
dst_ca.h
dst_common.h
dst_priv.h
dst.c
dvb-bt8xx.c
dvb-bt8xx.h
Kconfig
Makefile