call: update media on session progress.
@@ -2204,19 +2204,15 @@ static void sipsess_progr_handler(const struct sip_msg *msg, void *arg)
break;
}
- call_stream_stop(call);
-
- if (media)
- call_stream_start(call, false);
-
- if (media)
+ if (media) {
call_event_handler(call, CALL_EVENT_PROGRESS, call->peer_uri);
- else
- call_event_handler(call, CALL_EVENT_RINGING, call->peer_uri);
-
- if (media)
update_media(call);
}
+ else {
+ call_stream_stop(call);
+ call_event_handler(call, CALL_EVENT_RINGING, call->peer_uri);
+ }
+}
static void redirect_handler(const struct sip_msg *msg, const char *uri,
