1
0
mirror of https://github.com/rofafor/vdr-plugin-satip.git synced 2023-10-10 13:37:42 +02:00

Fix info messages.

This commit is contained in:
Rolf Ahrenberg 2017-07-31 16:18:45 +03:00
parent 537c0ad000
commit 1984ec662c

4
rtp.c
View File

@ -45,7 +45,7 @@ void cSatipRtp::Close(void)
sequenceNumberM = -1; sequenceNumberM = -1;
if (packetErrorsM) { if (packetErrorsM) {
info("Detected %d RTP packet errors [device %d]", packetErrorsM, tunerM.GetId()); info("Detected %d RTP packet error%s [device %d]", packetErrorsM, packetErrorsM == 1 ? "": "s", tunerM.GetId());
packetErrorsM = 0; packetErrorsM = 0;
lastErrorReportM = time(NULL); lastErrorReportM = time(NULL);
} }
@ -80,7 +80,7 @@ int cSatipRtp::GetHeaderLength(unsigned char *bufferP, unsigned int lengthP)
else if ((sequenceNumberM >= 0) && (((sequenceNumberM + 1) % 0xFFFF) != seq)) { else if ((sequenceNumberM >= 0) && (((sequenceNumberM + 1) % 0xFFFF) != seq)) {
packetErrorsM++; packetErrorsM++;
if (time(NULL) - lastErrorReportM > eReportIntervalS) { if (time(NULL) - lastErrorReportM > eReportIntervalS) {
info("Detected %d RTP packet errors [device %d]", packetErrorsM, tunerM.GetId()); info("Detected %d RTP packet error%s [device %d]", packetErrorsM, packetErrorsM == 1 ? "": "s", tunerM.GetId());
packetErrorsM = 0; packetErrorsM = 0;
lastErrorReportM = time(NULL); lastErrorReportM = time(NULL);
} }