Fix for #65 RTSP streams not disconnected on error

This commit is contained in:
maazl 2020-12-28 16:47:43 +01:00
parent 3d33f766b7
commit 6d6d6370b2
1 changed files with 3 additions and 0 deletions

View File

@ -120,12 +120,15 @@ void cSatipTuner::Action(void)
break;
case tsSet:
debug4("%s: tsSet [device %d]", __PRETTY_FUNCTION__, deviceIdM);
// some devices require TEARDOWN before new PLAY command
Disconnect();
if (Connect()) {
tuning.Set(eTuningTimeoutMs);
RequestState(tsTuned, smInternal);
UpdatePids(true);
}
else
Disconnect();
break;
case tsTuned:
debug4("%s: tsTuned [device %d]", __PRETTY_FUNCTION__, deviceIdM);