More fixes from Firefly (#84)

* fix missing retune resulting in black screen

(cherry picked from commit 0f20f764bce549f7866ab19a91d0850397de21ea)

* avoid empty and therefore useless requests to SATIP server

(cherry picked from commit 275afb68bc6a8a7fdc91600c8869815008c94d6d)

Co-authored-by: FireFly <christoph1.haubrich@arcor.de>
This commit is contained in:
Martin 2023-01-05 14:43:33 +01:00 committed by GitHub
parent a76ff4c25a
commit 02a842f95a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 6 additions and 3 deletions

View File

@ -244,6 +244,7 @@ bool cSatipTuner::Connect(void)
if (useTcp)
debug1("%s Requesting TCP [device %d]", __PRETTY_FUNCTION__, deviceIdM);
if (rtspM.Setup(*uri, rtpM.Port(), rtcpM.Port(), useTcp)) {
lastParamM = streamParamM;
keepAliveM.Set(timeoutM);
if (nextServerM.IsValid()) {
currentServerM = nextServerM;
@ -552,9 +553,11 @@ bool cSatipTuner::UpdatePids(bool forceP)
tnrParamM = param;
}
}
pidUpdateCacheM.Set(ePidUpdateIntervalMs);
if (!rtspM.Play(*uri))
return false;
if (paramadded) {
pidUpdateCacheM.Set(ePidUpdateIntervalMs);
if (!rtspM.Play(*uri))
return false;
}
addPidsM.Clear();
delPidsM.Clear();
}