Browse Source

MT#57719 Introduce the `media_unconfirm()` function

Introduce `media_unconfirm()` to do a selective handling
of medias to unkernelize the correlated to it streams.
This is analogue of the of the `__monologue_unconfirm()`
but for medias.

Change-Id: Id8ede0fc56412021c301e97764fd5dd070b7d484
pull/1722/head
Donat Zenichev 2 years ago
parent
commit
101cc3bb6c
2 changed files with 13 additions and 0 deletions
  1. +12
    -0
      daemon/call.c
  2. +1
    -0
      include/call.h

+ 12
- 0
daemon/call.c View File

@ -4210,6 +4210,18 @@ void __monologue_unkernelize(struct call_monologue *monologue, const char *reaso
}
}
}
/* must be called with call->master_lock held in W */
void __media_unconfirm(struct call_media *media, const char *reason) {
if (!media)
return;
for (GList *m = media->streams.head; m; m = m->next) {
struct packet_stream *stream = m->data;
__stream_unconfirm(stream, reason);
__unconfirm_sinks(&stream->rtp_sinks, reason);
__unconfirm_sinks(&stream->rtcp_sinks, reason);
}
}
void dialogue_unkernelize(struct call_monologue *ml, const char *reason) {
__monologue_unkernelize(ml, reason);


+ 1
- 0
include/call.h View File

@ -764,6 +764,7 @@ void call_media_state_machine(struct call_media *m);
void call_media_unkernelize(struct call_media *media, const char *);
void dialogue_unkernelize(struct call_monologue *ml, const char *);
void __monologue_unkernelize(struct call_monologue *monologue, const char *);
void __media_unconfirm(struct call_media *media, const char *);
void update_init_subscribers(struct call_monologue *ml, enum call_opmode opmode);
int call_stream_address46(char *o, struct packet_stream *ps, enum stream_address_format format,


Loading…
Cancel
Save