diff options
author | Klaus Schmidinger <vdr@tvdr.de> | 2009-04-13 13:55:23 +0200 |
---|---|---|
committer | Klaus Schmidinger <vdr@tvdr.de> | 2009-04-13 13:55:23 +0200 |
commit | 5b57bdebdcecf9e544cbf0af72b77106efa62d8f (patch) | |
tree | 49bc4305a3ba3a31161413c286085a6e715f6b0a /thread.c | |
parent | b36d06e1eaf89467410a45bd9b5c48ec61c878ff (diff) | |
download | vdr-5b57bdebdcecf9e544cbf0af72b77106efa62d8f.tar.gz vdr-5b57bdebdcecf9e544cbf0af72b77106efa62d8f.tar.bz2 |
Added cThread::SetIOPriority() and using it in cRemoveDeletedRecordingsThread
Diffstat (limited to 'thread.c')
-rw-r--r-- | thread.c | 8 |
1 files changed, 7 insertions, 1 deletions
@@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: thread.c 2.2 2008/09/06 09:39:43 kls Exp $ + * $Id: thread.c 2.3 2009/04/13 13:50:39 kls Exp $ */ #include "thread.h" @@ -226,6 +226,12 @@ void cThread::SetPriority(int Priority) LOG_ERROR; } +void cThread::SetIOPriority(int Priority) +{ + if (syscall(SYS_ioprio_set, 1, 0, (Priority & 0xff) | (2 << 13)) < 0) // best effort class + LOG_ERROR; +} + void cThread::SetDescription(const char *Description, ...) { free(description); |