Skip to content

Commit

Permalink
[media] az6007: fix incorrect memcpy
Browse files Browse the repository at this point in the history
Some parts of the C language are subtle and evil. This is one example.

Resolves-bug: https://bugzilla.kernel.org/show_bug.cgi?id=44041

Reported-by: dcb314@hotmail.com
Signed-off-by: Alan Cox <alan@linux.intel.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
  • Loading branch information
Alan-Cox authored and Mauro Carvalho Chehab committed Jul 31, 2012
1 parent c79a3c3 commit 5a7a570
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/media/dvb/dvb-usb/az6007.c
Original file line number Diff line number Diff line change
Expand Up @@ -590,7 +590,7 @@ static int az6007_read_mac_addr(struct dvb_usb_device *d, u8 mac[6])
int ret;

ret = az6007_read(d, AZ6007_READ_DATA, 6, 0, st->data, 6);
memcpy(mac, st->data, sizeof(mac));
memcpy(mac, st->data, 6);

if (ret > 0)
deb_info("%s: mac is %pM\n", __func__, mac);
Expand Down

0 comments on commit 5a7a570

Please sign in to comment.