Skip to content

Commit

Permalink
rabbitmq_consumer: fix a bug in "connection_id" modparam parsing
Browse files Browse the repository at this point in the history
Closes #1987

(cherry picked from commit 832ef45)
  • Loading branch information
rvlad-patrascu committed Mar 6, 2020
1 parent bb943d8 commit 424e247
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions modules/rabbitmq_consumer/rmq_connection.c
Expand Up @@ -72,9 +72,13 @@ int rmq_conn_add(modparam_t mtype, void *val)
it->s.s++, it->s.len--)
p.len++;
if (p.len == 0) {
LM_ERR("Empty connection parameter\n");
free_csv_record(p_list);
return -1;
if (it->next) {
LM_ERR("Empty connection parameter\n");
free_csv_record(p_list);
return -1;
} else {
break;
}
}

if (!strncasecmp(p.s, "uri", 3))
Expand Down

0 comments on commit 424e247

Please sign in to comment.