Skip to content

Commit c4bf29d

Browse files
committed
tm branches: Few quickfixes
1 parent 2630531 commit c4bf29d

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

dset.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -293,6 +293,8 @@ int append_msg_branch(struct msg_branch *branch)
293293
LM_ERR("oom 2\n");
294294
return E_OUT_OF_MEM;
295295
}
296+
memset((char *)new_br + idx * sizeof *new_br, 0,
297+
DSET_INCREMENT * sizeof *new_br);
296298

297299
dsct->branches = new_br;
298300
}

modules/tm/t_fwd.c

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -432,8 +432,10 @@ static int add_uac( struct cell *t, struct sip_msg *request, const str *uri,
432432
* Bottom line, we take over the attr list handling, so we NULL the
433433
* received holder (so the upper level will havve nothing to care furhter)
434434
*/
435-
t->uac[branch].battrs = *attrs;
436-
*attrs = NULL;
435+
if (attrs) {
436+
t->uac[branch].battrs = *attrs;
437+
*attrs = NULL;
438+
}
437439

438440
if ( pre_print_uac_request( t, branch, request, &body_clone)!= 0 ) {
439441
ret = -1;

0 commit comments

Comments
 (0)