mirror of
https://github.com/ossrs/srs.git
synced 2025-03-09 15:49:59 +00:00
For #1684, Prevent stop ingest for multiple times. 3.0.143
This commit is contained in:
parent
0aecc063e0
commit
905444a1c7
4 changed files with 11 additions and 7 deletions
|
@ -690,12 +690,13 @@ void SrsPlayEdge::on_all_client_stop()
|
|||
// when all client disconnected,
|
||||
// and edge is ingesting origin stream, abort it.
|
||||
if (state == SrsEdgeStatePlay || state == SrsEdgeStateIngestConnected) {
|
||||
state = SrsEdgeStateIngestStoping; // avoid multi call stop
|
||||
ingester->stop();
|
||||
|
||||
SrsEdgeState pstate = state;
|
||||
state = SrsEdgeStateIngestStopping;
|
||||
|
||||
ingester->stop();
|
||||
|
||||
state = SrsEdgeStateInit;
|
||||
srs_trace("edge change from %d to state %d (init).", pstate, state);
|
||||
srs_trace("edge change from %d to %d then %d (init).", pstate, SrsEdgeStateIngestStopping, state);
|
||||
|
||||
return;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue