+ drivers-media-dvb-dvb-usb-az6007c-fix-incorrect-memcpy.patch added to -mm tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The patch titled
     Subject: drivers/media/dvb/dvb-usb/az6007.c: fix incorrect memcpy
has been added to the -mm tree.  Its filename is
     drivers-media-dvb-dvb-usb-az6007c-fix-incorrect-memcpy.patch

Before you just go and hit "reply", please:
   a) Consider who else should be cc'ed
   b) Prefer to cc a suitable mailing list as well
   c) Ideally: find the original patch on the mailing list and do a
      reply-to-all to that, adding suitable additional cc's

*** Remember to use Documentation/SubmitChecklist when testing your code ***

The -mm tree is included into linux-next and is updated
there every 3-4 working days

------------------------------------------------------
From: Alan Cox <alan@xxxxxxxxxxxxxxx>
Subject: drivers/media/dvb/dvb-usb/az6007.c: fix incorrect memcpy

Some parts of the C language are subtle and evil. This is one example.

(akpm: sizeof returns sizeof(u8*) here).

Addresses https://bugzilla.kernel.org/show_bug.cgi?id=44041

Reported-by: David Binderman <dcb314@xxxxxxxxxxx>
Signed-off-by: Alan Cox <alan@xxxxxxxxxxxxxxx>
Cc: Mauro Carvalho Chehab <mchehab@xxxxxxxxxxxxx>
Cc: Jose Alberto Reguero <jareguero@xxxxxxxxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
---

 drivers/media/dvb/dvb-usb/az6007.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff -puN drivers/media/dvb/dvb-usb/az6007.c~drivers-media-dvb-dvb-usb-az6007c-fix-incorrect-memcpy drivers/media/dvb/dvb-usb/az6007.c
--- a/drivers/media/dvb/dvb-usb/az6007.c~drivers-media-dvb-dvb-usb-az6007c-fix-incorrect-memcpy
+++ a/drivers/media/dvb/dvb-usb/az6007.c
@@ -590,7 +590,7 @@ static int az6007_read_mac_addr(struct d
 	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);
_
Subject: Subject: drivers/media/dvb/dvb-usb/az6007.c: fix incorrect memcpy

Patches currently in -mm which might be from alan@xxxxxxxxxxxxxxx are

origin.patch
linux-next.patch
ppc-e500_tlb-memset-clears-nothing.patch
drivers-media-dvb-dvb-usb-az6007c-fix-incorrect-memcpy.patch
fs-make-dumpable=2-require-fully-qualified-path.patch
coredump-warn-about-unsafe-suid_dumpable-core_pattern-combo.patch
kernel-sysc-avoid-argv_freenull.patch
drivers-message-i2o-i2o_procc-the-pointer-returned-from-chtostr-points-to-an-array-which-is-no-longer-valid.patch

--
To unsubscribe from this list: send the line "unsubscribe mm-commits" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Kernel Newbies FAQ]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Photo]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux