summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKlaus Schmidinger <vdr@tvdr.de>2002-03-16 14:27:35 +0100
committerKlaus Schmidinger <vdr@tvdr.de>2002-03-16 14:27:35 +0100
commitf7d6a96935617ac43c7db0845330b957c96f603b (patch)
tree2e9b2e896ce32411420ac049c3049dd13568891f
parent25abe47a3b3ba1e518e96d9c4cbccadeff1bc480 (diff)
downloadvdr-f7d6a96935617ac43c7db0845330b957c96f603b.tar.gz
vdr-f7d6a96935617ac43c7db0845330b957c96f603b.tar.bz2
Fixed high CPU usage in transfer mode
-rw-r--r--HISTORY1
-rw-r--r--dvbapi.c4
2 files changed, 3 insertions, 2 deletions
diff --git a/HISTORY b/HISTORY
index 41bea83c..7d7cd391 100644
--- a/HISTORY
+++ b/HISTORY
@@ -1106,3 +1106,4 @@ Video Disk Recorder Revision History
- The "Left" and "Right" keys are now used to page up and down in text displays
(like the EPG descriptions or the results of commands executed from the
"Commands" menu).
+- Fixed high CPU usage in transfer mode.
diff --git a/dvbapi.c b/dvbapi.c
index b8214fa6..1ade142b 100644
--- a/dvbapi.c
+++ b/dvbapi.c
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: dvbapi.c 1.162 2002/03/10 11:01:38 kls Exp $
+ * $Id: dvbapi.c 1.163 2002/03/16 14:20:47 kls Exp $
*/
#include "dvbapi.h"
@@ -1411,7 +1411,7 @@ void cTransferBuffer::Output(void)
int r = Get(b, sizeof(b));
if (r > 0) {
uchar *p = b;
- while (r > 0 && Busy()) {
+ while (r > 0 && Busy() && cFile::FileReadyForWriting(toDevice, 100)) {
int w = write(toDevice, p, r);
if (w > 0) {
p += w;