1
0
mirror of https://github.com/VDR4Arch/vdr.git synced 2023-10-10 13:36:52 +02:00

Fixed generating the index file in the cutter

This commit is contained in:
Klaus Schmidinger 2022-12-01 12:47:33 +01:00
parent f2b9f0e8dd
commit 8d65cc6dc0
3 changed files with 5 additions and 3 deletions

View File

@ -2459,6 +2459,7 @@ Christoph Haubrich <christoph1.haubrich@arcor.de>
for reporting a problem with the call to EpgHandlers.EndSegmentTransfer()
for fixing handling zero bytes in cH264Parser
for implementing parsing frame rate and image size for MPEG2, H.264 and H.265
for reporting a bug in generating the index file in the cutter
Pekka Mauno <pekka.mauno@iki.fi>
for fixing cSchedule::GetFollowingEvent() in case there is currently no present

View File

@ -9816,6 +9816,7 @@ Video Disk Recorder Revision History
- Added missing rounding when dividing frequencies in processing the NIT (thanks to
Winfried Köhler).
2022-11-30:
2022-12-01:
- Fixed a compiler warning.
- Fixed generating the index file in the cutter (reported by Christoph Haubrich).

View File

@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
* $Id: recording.c 5.19 2022/11/28 14:39:23 kls Exp $
* $Id: recording.c 5.20 2022/12/01 12:47:33 kls Exp $
*/
#include "recording.h"
@ -2579,7 +2579,7 @@ cIndexFile::cIndexFile(const char *FileName, bool Record, bool IsPesRecording, b
cCondWait::SleepMs(INDEXFILETESTINTERVAL);
}
int delta = 0;
if (!Record && (access(fileName, R_OK) != 0 || FileSize(fileName) == 0)) {
if (!Record && (access(fileName, R_OK) != 0 || FileSize(fileName) == 0 && time(NULL) - LastModifiedTime(fileName) > MAXWAITFORINDEXFILE)) {
// Index file doesn't exist, so try to regenerate it:
if (!isPesRecording) { // sorry, can only do this for TS recordings
resumeFile.Delete(); // just in case