Browse Source

MT#56447 fix list pointer check

Check for EOL in the right places.

Change-Id: Ib9b9b1e08c585f3865a1c8ab0146b8a3eb3c7e39
Warned-by: Coverity
(cherry picked from commit 4e908d8128)
mr11.3.1
Richard Fuchs 3 years ago
parent
commit
80975a6b7d
1 changed files with 5 additions and 2 deletions
  1. +5
    -2
      daemon/call.c

+ 5
- 2
daemon/call.c View File

@ -3491,6 +3491,9 @@ int monologue_subscribe_answer(struct call_monologue *dst_ml, struct sdp_ng_flag
bool transcoding = false;
for (GList *l = streams->head; l; l = l->next) {
if (!src_ml_it)
return -1;
struct stream_params *sp = l->data;
// grab the matching source ml:
@ -3498,10 +3501,10 @@ int monologue_subscribe_answer(struct call_monologue *dst_ml, struct sdp_ng_flag
// the current source ml
if (src_media_it && !src_media_it->next) {
src_ml_it = src_ml_it->next;
if (!src_ml_it)
return -1;
index = 1; // starts over at 1
}
if (!src_ml_it)
return -1;
struct call_subscription *cs = src_ml_it->data;
struct call_monologue *src_ml = cs->monologue;


Loading…
Cancel
Save