mirror of
https://github.com/xcat2/xNBA.git
synced 2024-12-14 07:11:32 +00:00
convert to zalloc
This commit is contained in:
parent
7297f04481
commit
5ce16b03a1
@ -245,12 +245,11 @@ static int pcibus_probe ( struct root_device *rootdev ) {
|
||||
|
||||
/* Allocate struct pci_device */
|
||||
if ( ! pci )
|
||||
pci = malloc ( sizeof ( *pci ) );
|
||||
pci = zalloc ( sizeof ( *pci ) );
|
||||
if ( ! pci ) {
|
||||
rc = -ENOMEM;
|
||||
goto err;
|
||||
}
|
||||
memset ( pci, 0, sizeof ( *pci ) );
|
||||
pci->bus = bus;
|
||||
pci->devfn = devfn;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user