Shut down STUN stack before removing streams from Agent. (#202)
Should fix NPEs being thrown during Agent.free().
This commit is contained in:
parent
e6e36856c6
commit
7016902b21
@ -2382,6 +2382,9 @@ public class Agent
|
||||
terminate(IceProcessingState.TERMINATED);
|
||||
}
|
||||
|
||||
/* Stop all outstanding transactions */
|
||||
getStunStack().shutDown();
|
||||
|
||||
// Free its IceMediaStreams, Components and Candidates.
|
||||
boolean interrupted = false;
|
||||
|
||||
@ -2406,8 +2409,6 @@ public class Agent
|
||||
if (interrupted)
|
||||
Thread.currentThread().interrupt();
|
||||
|
||||
getStunStack().shutDown();
|
||||
|
||||
logger.debug(() -> "ICE agent freed");
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user