summaryrefslogtreecommitdiff
path: root/tools.c
diff options
context:
space:
mode:
authorKlaus Schmidinger <vdr@tvdr.de>2000-09-15 15:09:15 +0200
committerKlaus Schmidinger <vdr@tvdr.de>2000-09-15 15:09:15 +0200
commit7fbf9e6c49430ca2de4683dc7319aa32d247a0f6 (patch)
tree07f63040bdf138c88c96fca5bb019e2ab22d71a1 /tools.c
parent39600857613d85e035ab1f93ad8360d9eaf00fe0 (diff)
downloadvdr-7fbf9e6c49430ca2de4683dc7319aa32d247a0f6.tar.gz
vdr-7fbf9e6c49430ca2de4683dc7319aa32d247a0f6.tar.bz2
New option '-c'; config files in video directory by default
Diffstat (limited to 'tools.c')
-rw-r--r--tools.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/tools.c b/tools.c
index bd35f928..d854dfb1 100644
--- a/tools.c
+++ b/tools.c
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: tools.c 1.15 2000/09/15 13:30:24 kls Exp $
+ * $Id: tools.c 1.16 2000/09/15 14:45:31 kls Exp $
*/
#define _GNU_SOURCE
@@ -153,6 +153,14 @@ bool isnumber(const char *s)
return true;
}
+const char *AddDirectory(const char *DirName, const char *FileName)
+{
+ static char *buf = NULL;
+ delete buf;
+ asprintf(&buf, "%s/%s", DirName && *DirName ? DirName : ".", FileName);
+ return buf;
+}
+
#define DFCMD "df -m %s"
uint FreeDiskSpaceMB(const char *Directory)