Skip to content

Commit

Permalink
dialog: init output dlg var value param eariler
Browse files Browse the repository at this point in the history
(cherry picked from commit ce3cd42)
  • Loading branch information
miconda committed Sep 27, 2022
1 parent ddd4bc1 commit 547f8f0
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/modules/dialog/dlg_var.c
Expand Up @@ -310,14 +310,14 @@ int get_dlg_varval(struct dlg_cell *dlg, str *key, str *val)
{
str *var = NULL;

val->s = NULL;
val->len = 0;

if( !dlg || !key || key->len > strlen(key->s)) {
LM_ERR("BUG - bad parameters\n");
return -1;
}

val->s = NULL;
val->len = 0;

dlg_lock(d_table, &(d_table->entries[dlg->h_entry]));
var = get_dlg_variable_unsafe(dlg, key);
if(var) {
Expand Down

0 comments on commit 547f8f0

Please sign in to comment.