diff options
author | Holger Lubitz <hal@duncan.ol.sub.de> | 2007-07-06 21:08:41 +0200 |
---|---|---|
committer | Holger Lubitz <hal@duncan.ol.sub.de> | 2007-07-06 21:08:41 +0200 |
commit | 389c63d7c450507b99d9db2e0c1cfe6397f03246 (patch) | |
tree | db3b161e2d1a73079768f245bf27947bfba84fcb /src/net/udp.c | |
parent | 32e4ca8ae3c5989ef3d73130acff48c918ea9693 (diff) | |
download | ipxe-389c63d7c450507b99d9db2e0c1cfe6397f03246.zip ipxe-389c63d7c450507b99d9db2e0c1cfe6397f03246.tar.gz ipxe-389c63d7c450507b99d9db2e0c1cfe6397f03246.tar.bz2 |
convert to zalloc
Diffstat (limited to 'src/net/udp.c')
-rw-r--r-- | src/net/udp.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/net/udp.c b/src/net/udp.c index c6216d8..ad999c0 100644 --- a/src/net/udp.c +++ b/src/net/udp.c @@ -104,11 +104,10 @@ static int udp_open_common ( struct xfer_interface *xfer, int rc; /* Allocate and initialise structure */ - udp = malloc ( sizeof ( *udp ) ); + udp = zalloc ( sizeof ( *udp ) ); if ( ! udp ) return -ENOMEM; DBGC ( udp, "UDP %p allocated\n", udp ); - memset ( udp, 0, sizeof ( *udp ) ); xfer_init ( &udp->xfer, &udp_xfer_operations, &udp->refcnt ); memcpy ( &udp->peer, st_peer, sizeof ( udp->peer ) ); |