Fixed a problem with accessing the epg.data file before it is fully written

This commit is contained in:
Klaus Schmidinger 2002-04-06 11:49:04 +02:00
parent 7babc1034e
commit cb0e6f1b14
3 changed files with 7 additions and 4 deletions

View File

@ -186,6 +186,7 @@ Norbert Schmidt <nschmidt-nrw@t-online.de>
Thilo Wunderlich <tw@ubcom.net>
for his help in keeping 'channels.conf' up to date
for reporting a problem with accessing the epg.data file before it is fully written
Stephan Schreiber <stephan@sschreiber.de>
for his support in keeping the Premiere World channels up to date in 'channels.conf.cable'

View File

@ -1180,3 +1180,5 @@ Video Disk Recorder Revision History
- Fixed resetting the "First day" timer parameter once the timer actually starts
recording.
- Fixed the still picture workaround in case the progress display is active.
- Fixed a problem with accessing the epg.data file before it is fully written
(thanks to Thilo Wunderlich for reporting this one).

8
eit.c
View File

@ -16,7 +16,7 @@
* the Free Software Foundation; either version 2 of the License, or *
* (at your option) any later version. *
* *
* $Id: eit.c 1.42 2002/04/01 12:58:20 kls Exp $
* $Id: eit.c 1.43 2002/04/06 11:42:47 kls Exp $
***************************************************************************/
#include "eit.h"
@ -1090,10 +1090,10 @@ void cSIProcessor::Action()
if (epgDataFileName && now - lastDump > 600)
{
cMutexLock MutexLock(&schedulesMutex);
FILE *f = fopen(GetEpgDataFileName(), "w");
if (f) {
cSafeFile f(GetEpgDataFileName());
if (f.Open()) {
schedules->Dump(f);
fclose(f);
f.Close();
}
else
LOG_ERROR;