vdr_streamdev: use full 64-bit from stat for recordings.
[people/teissler/ipfire-2.x.git] / src / patches / vdr-streamdev_recordings-64.patch
CommitLineData
f5fc6d31
AF
1diff -Naur vdr-streamdev-10db11ac.org/server/connectionHTTP.c vdr-streamdev-10db11ac/server/connectionHTTP.c
2--- vdr-streamdev-10db11ac.org/server/connectionHTTP.c 2013-02-18 12:43:02.000000000 +0100
3+++ vdr-streamdev-10db11ac/server/connectionHTTP.c 2013-04-29 15:16:40.049168127 +0200
4@@ -455,11 +455,11 @@
5 return NULL;
6
7 char *p = NULL;
8- unsigned long l = strtoul(FileBase, &p, 0);
9+ unsigned long long l = strtoull(FileBase, &p, 0);
10 if (p != FileBase && l > 0L) {
11 if (*p == ':') {
12 // get recording by dev:inode
13- unsigned long inode = strtoul(p + 1, &p, 0);
14+ unsigned long long inode = strtoull(p + 1, &p, 0);
15 if (*p == 0 && inode > 0) {
16 struct stat st;
17 cThreadLock RecordingsLock(&Recordings);
ab76260b
AF
18diff -Naur vdr-streamdev-10db11ac.org/server/menuHTTP.c vdr-streamdev-10db11ac/server/menuHTTP.c
19--- vdr-streamdev-10db11ac.org/server/menuHTTP.c 2013-02-18 12:43:02.000000000 +0100
f5fc6d31 20+++ vdr-streamdev-10db11ac/server/menuHTTP.c 2013-04-29 15:15:30.352502787 +0200
ab76260b
AF
21@@ -28,7 +28,7 @@
22 {
23 struct stat st;
24 if (stat(current->FileName(), &st) == 0)
25- return cString::sprintf("%lu:%lu.rec", st.st_dev, st.st_ino);
f5fc6d31 26+ return cString::sprintf("%llu:%llu.rec", (unsigned long long) st.st_dev, (unsigned long long) st.st_ino);
ab76260b
AF
27 return "";
28 }
29