summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKlaus Schmidinger <vdr@tvdr.de>2009-02-01 10:15:47 +0100
committerKlaus Schmidinger <vdr@tvdr.de>2009-02-01 10:15:47 +0100
commit6a6aac9dd37fa19db11adead264405313f795e23 (patch)
tree15b44ebe59a8858f1c30b4013175bcadba05bc1d
parent9a7473eaf3f1512dc213cafe563c6a9d1a6c974b (diff)
downloadvdr-6a6aac9dd37fa19db11adead264405313f795e23.tar.gz
vdr-6a6aac9dd37fa19db11adead264405313f795e23.tar.bz2
Added cap_sys_nice to the capabilities that are not dropped
-rw-r--r--CONTRIBUTORS1
-rw-r--r--HISTORY4
-rw-r--r--vdr.c10
3 files changed, 9 insertions, 6 deletions
diff --git a/CONTRIBUTORS b/CONTRIBUTORS
index 37abef58..0afcd6a9 100644
--- a/CONTRIBUTORS
+++ b/CONTRIBUTORS
@@ -1061,6 +1061,7 @@ Rolf Ahrenberg <rahrenbe@cc.hut.fi>
the last replayed recording was in a subdirectory, and pressing Back
for setting the thread name, so that it can be seen in 'top -H'
for replacing the Finnish language code "smi" with "suo"
+ for adding cap_sys_nice to the capabilities that are not dropped
Ralf Klueber <ralf.klueber@vodafone.com>
for reporting a bug in cutting a recording if there is only a single editing mark
diff --git a/HISTORY b/HISTORY
index 9cb133bb..0cc1e91b 100644
--- a/HISTORY
+++ b/HISTORY
@@ -5979,8 +5979,10 @@ Video Disk Recorder Revision History
cDevice class reimplements PlayTs() or PlayPes(), it also needs to make sure this
new function works as expected.
-2009-01-30: Version 1.7.5
+2009-02-01: Version 1.7.5
- Fixed a hangup when replaying a TS recording with subtitles activated (reported
by Timo Helkio).
- Fixed handling the 'new' indicator in the recordings menu for TS recordings.
+- Added cap_sys_nice to the capabilities that are not dropped (thanks to Rolf
+ Ahrenberg).
diff --git a/vdr.c b/vdr.c
index 34ad856f..60fc11a1 100644
--- a/vdr.c
+++ b/vdr.c
@@ -22,7 +22,7 @@
*
* The project's page is at http://www.cadsoft.de/vdr
*
- * $Id: vdr.c 2.4 2009/01/18 11:02:37 kls Exp $
+ * $Id: vdr.c 2.5 2009/02/01 10:13:48 kls Exp $
*/
#include <getopt.h>
@@ -112,10 +112,10 @@ static bool SetUser(const char *UserName, bool UserDump)//XXX name?
return true;
}
-static bool SetCapSysTime(void)
+static bool DropCaps(void)
{
- // drop all capabilities except cap_sys_time
- cap_t caps = cap_from_text("= cap_sys_time=ep");
+ // drop all capabilities except selected ones
+ cap_t caps = cap_from_text("= cap_sys_nice,cap_sys_time=ep");
if (!caps) {
fprintf(stderr, "vdr: cap_from_text failed: %s\n", strerror(errno));
return false;
@@ -387,7 +387,7 @@ int main(int argc, char *argv[])
return 2;
if (!SetKeepCaps(false))
return 2;
- if (!SetCapSysTime())
+ if (!DropCaps())
return 2;
}
}