diff options
author | Harald Welte <laforge@gnumonks.org> | 2009-06-26 20:25:23 +0200 |
---|---|---|
committer | Harald Welte <laforge@gnumonks.org> | 2009-06-26 20:25:23 +0200 |
commit | 470ec29b0db526c1592f6a270652657315efddca (patch) | |
tree | 7da372db125bc09f31076a57e484165641c3d3ff /openbsc/src/abis_nm.c | |
parent | c05677b036dce4dbf59414dc15b75a5b3472ae6e (diff) |
use taloc_zero() rather than talloc() and explisit memset()
Diffstat (limited to 'openbsc/src/abis_nm.c')
-rw-r--r-- | openbsc/src/abis_nm.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/openbsc/src/abis_nm.c b/openbsc/src/abis_nm.c index 4a73930fc..b07aa3116 100644 --- a/openbsc/src/abis_nm.c +++ b/openbsc/src/abis_nm.c @@ -2079,12 +2079,11 @@ static int bs11_read_swl_file(struct abis_nm_bs11_sw *bs11_sw) if (rc < 2) continue; - fle = talloc(tall_fle_ctx, struct file_list_entry); + fle = talloc_zero(tall_fle_ctx, struct file_list_entry); if (!fle) { rc = -ENOMEM; goto out; } - memset(fle, 0, sizeof(*fle)); /* construct new filename */ strncpy(dir, bs11_sw->swl_fname, sizeof(dir)); |