summaryrefslogtreecommitdiff
path: root/tools.h
diff options
context:
space:
mode:
authorKlaus Schmidinger <vdr@tvdr.de>2002-01-26 12:04:32 +0100
committerKlaus Schmidinger <vdr@tvdr.de>2002-01-26 12:04:32 +0100
commit503c803b8d97e7997bc2a5c42eb6a2014d013528 (patch)
treec58f7f220f0d54e87dbf028a74e6cf1975ad95b4 /tools.h
parentfe7b03d6b5ecc1e3fbb2804fe179669f8f111c7a (diff)
downloadvdr-503c803b8d97e7997bc2a5c42eb6a2014d013528.tar.gz
vdr-503c803b8d97e7997bc2a5c42eb6a2014d013528.tar.bz2
Fixed handling file names that contain single quotes or dollar signs in calls to external commands
Diffstat (limited to 'tools.h')
-rw-r--r--tools.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/tools.h b/tools.h
index 933b797e..8bb09699 100644
--- a/tools.h
+++ b/tools.h
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: tools.h 1.37 2002/01/20 15:39:53 kls Exp $
+ * $Id: tools.h 1.38 2002/01/26 11:55:06 kls Exp $
*/
#ifndef __TOOLS_H
@@ -50,13 +50,14 @@ char *strreplace(char *s, char c1, char c2);
char *skipspace(const char *s);
char *stripspace(char *s);
char *compactspace(char *s);
+const char *strescape(const char *s, const char *chars); // returns a statically allocated string!
bool startswith(const char *s, const char *p);
bool endswith(const char *s, const char *p);
bool isempty(const char *s);
int time_ms(void);
void delay_ms(int ms);
bool isnumber(const char *s);
-const char *AddDirectory(const char *DirName, const char *FileName);
+const char *AddDirectory(const char *DirName, const char *FileName); // returns a statically allocated string!
uint FreeDiskSpaceMB(const char *Directory);
bool DirectoryOk(const char *DirName, bool LogErrors = false);
bool MakeDirs(const char *FileName, bool IsDirectory = false);
@@ -64,7 +65,7 @@ bool RemoveFileOrDir(const char *FileName, bool FollowSymlinks = false);
bool RemoveEmptyDirectories(const char *DirName, bool RemoveThis = false);
char *ReadLink(const char *FileName);
bool SpinUpDisk(const char *FileName);
-const char *DayDateTime(time_t t = 0);
+const char *DayDateTime(time_t t = 0); // returns a statically allocated string!
class cFile {
private: