david/ipxe
david
/
ipxe
Archived
1
0
Fork 0

convert to zalloc

This commit is contained in:
Holger Lubitz 2007-07-06 21:08:54 +02:00
parent 389c63d7c4
commit a4d3476e0e
1 changed files with 1 additions and 2 deletions

View File

@ -787,10 +787,9 @@ int start_dhcp ( struct job_interface *job, struct net_device *netdev,
int rc;
/* Allocate and initialise structure */
dhcp = malloc ( sizeof ( *dhcp ) );
dhcp = zalloc ( sizeof ( *dhcp ) );
if ( ! dhcp )
return -ENOMEM;
memset ( dhcp, 0, sizeof ( *dhcp ) );
dhcp->refcnt.free = dhcp_free;
job_init ( &dhcp->job, &dhcp_job_operations, &dhcp->refcnt );
xfer_init ( &dhcp->xfer, &dhcp_xfer_operations, &dhcp->refcnt );