wok diff memtest/stuff/memtest86+-5.01-array-size.patch @ rev 21820

syslinux/kbd: check kbd malloc pointer
author Pascal Bellard <pascal.bellard@slitaz.org>
date Sun Aug 25 11:41:26 2019 +0200 (2019-08-25)
parents
children d44f69067aca
line diff
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/memtest/stuff/memtest86+-5.01-array-size.patch	Sun Aug 25 11:41:26 2019 +0200
     1.3 @@ -0,0 +1,20 @@
     1.4 +--- memtest86+-5.01/controller.c~	2013-08-10 02:01:58.000000000 +0000
     1.5 ++++ memtest86+-5.01/controller.c	2013-12-12 20:58:12.873555378 +0000
     1.6 +@@ -292,7 +292,7 @@
     1.7 + 
     1.8 + 	/* First, locate the PCI bus where the MCH is located */
     1.9 + 
    1.10 +-	for(i = 0; i < sizeof(possible_nhm_bus); i++) {
    1.11 ++	for(i = 0; i < sizeof(possible_nhm_bus) / sizeof(possible_nhm_bus[0]); i++) {
    1.12 + 		pci_conf_read( possible_nhm_bus[i], 3, 4, 0x00, 2, &vid);
    1.13 + 		pci_conf_read( possible_nhm_bus[i], 3, 4, 0x02, 2, &did);
    1.14 + 		vid &= 0xFFFF;
    1.15 +@@ -327,7 +327,7 @@
    1.16 + 	ctrl.mode = ECC_NONE;
    1.17 + 
    1.18 + 	/* First, locate the PCI bus where the MCH is located */
    1.19 +-	for(i = 0; i < sizeof(possible_nhm_bus); i++) {
    1.20 ++	for(i = 0; i < sizeof(possible_nhm_bus) / sizeof(possible_nhm_bus[0]); i++) {
    1.21 + 		pci_conf_read( possible_nhm_bus[i], 3, 4, 0x00, 2, &vid);
    1.22 + 		pci_conf_read( possible_nhm_bus[i], 3, 4, 0x02, 2, &did);
    1.23 + 		vid &= 0xFFFF;