summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKlaus Schmidinger <vdr@tvdr.de>2006-07-30 10:29:24 +0200
committerKlaus Schmidinger <vdr@tvdr.de>2006-07-30 10:29:24 +0200
commitae4633feb04b4665ea561dea4c88dea28e8d9032 (patch)
treec38e0a15f496450d9121bac7ddb68aad2e03c399
parentcacd58d0362b26190df7cb1505ac1c75a41a45ab (diff)
downloadvdr-ae4633feb04b4665ea561dea4c88dea28e8d9032.tar.gz
vdr-ae4633feb04b4665ea561dea4c88dea28e8d9032.tar.bz2
Now invalidating /video cache _after_ cutting
-rw-r--r--CONTRIBUTORS2
-rw-r--r--HISTORY4
-rw-r--r--cutter.c5
-rw-r--r--recording.c7
-rw-r--r--recording.h4
5 files changed, 14 insertions, 8 deletions
diff --git a/CONTRIBUTORS b/CONTRIBUTORS
index 7cd104b0..4ed23435 100644
--- a/CONTRIBUTORS
+++ b/CONTRIBUTORS
@@ -279,6 +279,8 @@ Artur Skawina <skawina@geocities.com>
for a patch that contained a fix for checking toFile in cCuttingThread::Action()
for improving cUnbufferedFile
for fixing calculating the cache size in cUnbufferedFile::Read()
+ for making the /video/.update file be touched _after_ an editing process is finished
+ in order to avoid excessive disk access
Werner Fink <werner@suse.de>
for making I/O more robust by handling EINTR
diff --git a/HISTORY b/HISTORY
index df5cfa7b..35d1815e 100644
--- a/HISTORY
+++ b/HISTORY
@@ -4835,7 +4835,7 @@ Video Disk Recorder Revision History
only done for normal keypresses, not for repeated ones. This allows the user to
scroll the value all the way to the limit by keeping the key pressed.
-2006-07-29: Version 1.4.1-3
+2006-07-30: Version 1.4.1-3
- Fixed assigning schedules to channels in case there is no initial EPG information
(thanks to Frank Schmirler).
@@ -4844,3 +4844,5 @@ Video Disk Recorder Revision History
- Fixed cDevice::ToggleMute() (thanks to Christoph Haubrich).
- Fixed deleting the last character of a string menu item in insert mode (thanks
to Udo Richter).
+- The /video/.update file is now touched _after_ an editing process is finished
+ in order to avoid excessive disk access (thanks to Artur Skawina).
diff --git a/cutter.c b/cutter.c
index 5b82cc54..5170ae4a 100644
--- a/cutter.c
+++ b/cutter.c
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: cutter.c 1.15 2006/02/12 10:07:23 kls Exp $
+ * $Id: cutter.c 1.16 2006/07/30 10:22:08 kls Exp $
*/
#include "cutter.h"
@@ -171,6 +171,7 @@ void cCuttingThread::Action(void)
LastMark = true;
}
}
+ Recordings.TouchUpdate();
}
else
esyslog("no editing marks found!");
@@ -205,7 +206,7 @@ bool cCutter::Start(const char *FileName)
// XXX
editedVersionName = strdup(evn);
Recording.WriteInfo();
- Recordings.AddByName(editedVersionName);
+ Recordings.AddByName(editedVersionName, false);
cuttingThread = new cCuttingThread(FileName, editedVersionName);
return true;
}
diff --git a/recording.c b/recording.c
index 229cfee5..fd7800b4 100644
--- a/recording.c
+++ b/recording.c
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: recording.c 1.148 2006/04/29 13:22:20 kls Exp $
+ * $Id: recording.c 1.149 2006/07/30 10:23:46 kls Exp $
*/
#include "recording.h"
@@ -970,7 +970,7 @@ cRecording *cRecordings::GetByName(const char *FileName)
return NULL;
}
-void cRecordings::AddByName(const char *FileName)
+void cRecordings::AddByName(const char *FileName, bool TriggerUpdate)
{
LOCK_THREAD;
cRecording *recording = GetByName(FileName);
@@ -978,7 +978,8 @@ void cRecordings::AddByName(const char *FileName)
recording = new cRecording(FileName);
Add(recording);
ChangeState();
- TouchUpdate();
+ if (TriggerUpdate)
+ TouchUpdate();
}
}
diff --git a/recording.h b/recording.h
index 28656855..def351f8 100644
--- a/recording.h
+++ b/recording.h
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: recording.h 1.54 2006/04/09 13:47:11 kls Exp $
+ * $Id: recording.h 1.55 2006/07/30 10:24:07 kls Exp $
*/
#ifndef __RECORDING_H
@@ -133,7 +133,7 @@ public:
bool StateChanged(int &State);
void ResetResume(const char *ResumeFileName = NULL);
cRecording *GetByName(const char *FileName);
- void AddByName(const char *FileName);
+ void AddByName(const char *FileName, bool TriggerUpdate = true);
void DelByName(const char *FileName);
int TotalFileSizeMB(void); ///< Only for deleted recordings!
};