Skip to content

Commit

Permalink
Time for preview max 10 minutes into the program
Browse files Browse the repository at this point in the history
The time of the preview is 1/3 of the total program duration
limited to 10 minutes after the start of the program.
This limit is added to prevent accidentally revealing the
result of sport events in long recordings.

(cherry picked from commit b571d81)
Signed-off-by: Klaas de Waal <klaas@kldo.nl>
  • Loading branch information
kmdewaal committed Sep 21, 2020
1 parent 2e1cccb commit 8ca7747
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion mythtv/libs/libmythtv/previewgenerator.cpp
Expand Up @@ -677,7 +677,10 @@ bool PreviewGenerator::LocalPreviewRun(void)
}
if (programDuration > 0)
{
captime = startEarly + (programDuration / 3);
captime = programDuration / 3;
if (captime > 600)
captime = 600;
captime += startEarly;
}
if (captime < 0)
captime = 600;
Expand Down

0 comments on commit 8ca7747

Please sign in to comment.