summaryrefslogtreecommitdiff
path: root/tools.c
diff options
context:
space:
mode:
authorKlaus Schmidinger <vdr@tvdr.de>2012-02-19 11:50:20 +0100
committerKlaus Schmidinger <vdr@tvdr.de>2012-02-19 11:50:20 +0100
commit23ec57d8229be5c0a2eaa12fa313ceb8b49fc962 (patch)
treedf01fdf5fe16d652783aec64320c7fcf98464dd9 /tools.c
parent50e09d1232c8d01a8a3f570aa8b3044f8d46a2e6 (diff)
downloadvdr-23ec57d8229be5c0a2eaa12fa313ceb8b49fc962.tar.gz
vdr-23ec57d8229be5c0a2eaa12fa313ceb8b49fc962.tar.bz2
Fixed switching into time shift mode when pausing live video1.7.24
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 145af7af..3296b540 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 2.21 2012/02/17 13:58:49 kls Exp $
+ * $Id: tools.c 2.22 2012/02/18 15:30:35 kls Exp $
*/
#include "tools.h"
@@ -563,6 +563,14 @@ time_t LastModifiedTime(const char *FileName)
return 0;
}
+off_t FileSize(const char *FileName)
+{
+ struct stat fs;
+ if (stat(FileName, &fs) == 0)
+ return fs.st_size;
+ return -1;
+}
+
// --- cTimeMs ---------------------------------------------------------------
cTimeMs::cTimeMs(int Ms)