Skip to content

Commit

Permalink
rtpengine: ensure new elems are initialized in sockets array
Browse files Browse the repository at this point in the history
  • Loading branch information
john08burke committed Apr 18, 2022
1 parent 0639385 commit 1eac785
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions modules/rtpengine/rtpengine.c
Original file line number Diff line number Diff line change
Expand Up @@ -1570,6 +1570,7 @@ static inline int rtpengine_connect_node(struct rtpe_node *pnode)

static int connect_rtpengines(int force_test)
{
int i;
struct rtpe_set *rtpe_list;
struct rtpe_node *pnode;

Expand All @@ -1585,6 +1586,8 @@ static int connect_rtpengines(int force_test)
LM_ERR("no more pkg memory\n");
return -1;
}
for (i=rtpe_number; i<*rtpe_no; i++)
rtpe_socks[i] = -1; /* init new elems */
}
rtpe_number = *rtpe_no;

Expand Down

0 comments on commit 1eac785

Please sign in to comment.