summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKlaus Schmidinger <vdr@tvdr.de>2015-04-11 10:47:38 +0200
committerKlaus Schmidinger <vdr@tvdr.de>2015-04-11 10:47:38 +0200
commit7d4907507916b555ae8cdd33f9741ed7ae704ad7 (patch)
tree46945f5026dc298ba053ca78a8efc71612c6453e
parent577d43facf1f1049e5b3ee83fcdea41f61004a6d (diff)
downloadvdr-7d4907507916b555ae8cdd33f9741ed7ae704ad7.tar.gz
vdr-7d4907507916b555ae8cdd33f9741ed7ae704ad7.tar.bz2
Reduced the priority of the "video directory scanner" thread and checking cIoThrottle::Engaged() when it is running
-rw-r--r--CONTRIBUTORS1
-rw-r--r--HISTORY4
-rw-r--r--recording.c6
3 files changed, 8 insertions, 3 deletions
diff --git a/CONTRIBUTORS b/CONTRIBUTORS
index f4a667fc..d80adb5c 100644
--- a/CONTRIBUTORS
+++ b/CONTRIBUTORS
@@ -3316,6 +3316,7 @@ Thomas Reufer <thomas@reufer.ch>
for adding detection of 24fps
for suggesting to add some comment to cPixmap about the relation between OSD,
ViewPort and DrawPort
+ for suggesting to reduce the priority of the "video directory scanner" thread
Eike Sauer <EikeSauer@t-online.de>
for reporting a problem with channels that need more than 5 TS packets for detecting
diff --git a/HISTORY b/HISTORY
index 13d450d6..e4703349 100644
--- a/HISTORY
+++ b/HISTORY
@@ -8596,7 +8596,7 @@ Video Disk Recorder Revision History
- Bumped all version numbers to 2.2.0.
- Official release.
-2015-03-25: Version 2.3.1
+2015-04-11: Version 2.3.1
- The new function cOsd::MaxPixmapSize() can be called to determine the maximum size
a cPixmap may have on the current OSD. The 'osddemo' example has been modified
@@ -8620,3 +8620,5 @@ Video Disk Recorder Revision History
(suggested by Thomas Reufer).
- Improved syncing on sections when parsing the NIT and SDT.
- Fixed scaling subtitles (their areas could sometimes extend outside the actual OSD).
+- Reduced the priority of the "video directory scanner" thread (suggested by Thomas
+ Reufer) and checking cIoThrottle::Engaged() when it is running.
diff --git a/recording.c b/recording.c
index 0a084140..0164bb97 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 3.28 2015/02/16 07:49:14 kls Exp $
+ * $Id: recording.c 4.1 2015/04/11 10:44:38 kls Exp $
*/
#include "recording.h"
@@ -1367,7 +1367,7 @@ cRecordings Recordings;
char *cRecordings::updateFileName = NULL;
cRecordings::cRecordings(bool Deleted)
-:cThread("video directory scanner")
+:cThread("video directory scanner", true)
{
deleted = Deleted;
initial = true;
@@ -1412,6 +1412,8 @@ bool cRecordings::ScanVideoDir(const char *DirName, bool Foreground, int LinkLev
cReadDir d(DirName);
struct dirent *e;
while ((Foreground || Running()) && (e = d.Next()) != NULL) {
+ if (!Foreground && cIoThrottle::Engaged())
+ cCondWait::SleepMs(100);
cString buffer = AddDirectory(DirName, e->d_name);
struct stat st;
if (lstat(buffer, &st) == 0) {