mirror of
				https://github.com/vdr-projects/vdr.git
				synced 2025-03-01 10:50:46 +00:00 
			
		
		
		
	Fixed regenerating the index file of a recording in case it is present, but empty
This commit is contained in:
		@@ -3563,6 +3563,8 @@ Stefan Herdler <herdler@gmx.de>
 | 
			
		||||
 ".sort" file
 | 
			
		||||
 for reporting faulty memory handling in cString::Append()
 | 
			
		||||
 for adding failsafe defaults for 'make LCLBLD=1' to the Makefile
 | 
			
		||||
 for reporting the index file of a recording not being regenerated in case it is
 | 
			
		||||
 present, but empty
 | 
			
		||||
 | 
			
		||||
Tobias Faust <tobias.faust@gmx.de>
 | 
			
		||||
 for the original "jumpingseconds" patch
 | 
			
		||||
 
 | 
			
		||||
							
								
								
									
										2
									
								
								HISTORY
									
									
									
									
									
								
							
							
						
						
									
										2
									
								
								HISTORY
									
									
									
									
									
								
							@@ -9811,3 +9811,5 @@ Video Disk Recorder Revision History
 | 
			
		||||
  or above.
 | 
			
		||||
- Added periodic calls to malloc_trim(0) to reduce memory consumption (thanks to
 | 
			
		||||
  Onur Sent<6E>rk).
 | 
			
		||||
- Fixed regenerating the index file of a recording in case it is present, but empty
 | 
			
		||||
  (reported by Stefan Herdler).
 | 
			
		||||
 
 | 
			
		||||
@@ -4,7 +4,7 @@
 | 
			
		||||
 * See the main source file 'vdr.c' for copyright information and
 | 
			
		||||
 * how to reach the author.
 | 
			
		||||
 *
 | 
			
		||||
 * $Id: recording.c 5.18 2022/11/22 14:33:48 kls Exp $
 | 
			
		||||
 * $Id: recording.c 5.19 2022/11/28 14:39:23 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) {
 | 
			
		||||
     if (!Record && (access(fileName, R_OK) != 0 || FileSize(fileName) == 0)) {
 | 
			
		||||
        // 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
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user