summaryrefslogtreecommitdiff
path: root/src/gsmd
diff options
context:
space:
mode:
Diffstat (limited to 'src/gsmd')
-rw-r--r--src/gsmd/timer.c2
-rw-r--r--src/gsmd/usock.c6
2 files changed, 4 insertions, 4 deletions
diff --git a/src/gsmd/timer.c b/src/gsmd/timer.c
index 648676f..31901c7 100644
--- a/src/gsmd/timer.c
+++ b/src/gsmd/timer.c
@@ -160,7 +160,7 @@ struct gsmd_timer *gsmd_timer_alloc(void)
{
struct gsmd_timer *tmr;
- tmr = talloc_size(__tmr_ctx, sizeof(*tmr));
+ tmr = talloc_zero_size(__tmr_ctx, sizeof(*tmr));
return tmr;
}
diff --git a/src/gsmd/usock.c b/src/gsmd/usock.c
index aa2c7b5..5e5b5c3 100644
--- a/src/gsmd/usock.c
+++ b/src/gsmd/usock.c
@@ -47,7 +47,7 @@ static void *__ucmd_ctx, *__gu_ctx;
struct gsmd_ucmd *ucmd_alloc(int extra_size)
{
- return talloc_size(__ucmd_ctx,
+ return talloc_zero_size(__ucmd_ctx,
sizeof(struct gsmd_ucmd) + extra_size);
}
@@ -986,7 +986,7 @@ static int network_opers_parse(const char *str, struct gsmd_msg_oper **out)
str++;
}
- *out = talloc_size(__gu_ctx, sizeof(struct gsmd_msg_oper) * (len + 1));
+ *out = talloc_zero_size(__gu_ctx, sizeof(struct gsmd_msg_oper) * (len + 1));
if (!out)
return -ENOMEM;
@@ -1120,7 +1120,7 @@ static int network_ownnumbers_cb(struct gsmd_atcmd *cmd, void *ctx, char *resp)
else
len = 0;
- num = talloc_size(__gu_ctx, sizeof(*num) + len + 1);
+ num = talloc_zero_size(__gu_ctx, sizeof(*num) + len + 1);
if (len)
ret = sscanf(resp, "+CNUM: \"%[^\"]\",\"%32[^\"]\",%i,%*i,%i,",
num->name, num->addr.number,
personal git repositories of Harald Welte. Your mileage may vary