Преглед изворни кода

Revert "convert to zalloc"

This reverts commit 5ce16b03a1.
tags/v0.9.3
Holger Lubitz пре 18 година
родитељ
комит
a772dc4a2a
1 измењених фајлова са 2 додато и 1 уклоњено
  1. 2
    1
      src/drivers/bus/pci.c

+ 2
- 1
src/drivers/bus/pci.c Прегледај датотеку

245
 
245
 
246
 			/* Allocate struct pci_device */
246
 			/* Allocate struct pci_device */
247
 			if ( ! pci )
247
 			if ( ! pci )
248
-				pci = zalloc ( sizeof ( *pci ) );
248
+				pci = malloc ( sizeof ( *pci ) );
249
 			if ( ! pci ) {
249
 			if ( ! pci ) {
250
 				rc = -ENOMEM;
250
 				rc = -ENOMEM;
251
 				goto err;
251
 				goto err;
252
 			}
252
 			}
253
+			memset ( pci, 0, sizeof ( *pci ) );
253
 			pci->bus = bus;
254
 			pci->bus = bus;
254
 			pci->devfn = devfn;
255
 			pci->devfn = devfn;
255
 			
256
 			

Loading…
Откажи
Сачувај