summaryrefslogtreecommitdiff
path: root/timers.c
diff options
context:
space:
mode:
authorKlaus Schmidinger <vdr@tvdr.de>2006-01-06 14:31:57 +0100
committerKlaus Schmidinger <vdr@tvdr.de>2006-01-06 14:31:57 +0100
commit72e93b614bac42cd4a142b10d47e5b1673f19800 (patch)
tree985000a2d5572c83903247fec904df04fb8c64c3 /timers.c
parent16f037e3c23efadcc846fd7dc780b42036fabf01 (diff)
downloadvdr-72e93b614bac42cd4a142b10d47e5b1673f19800.tar.gz
vdr-72e93b614bac42cd4a142b10d47e5b1673f19800.tar.bz2
The "flags" of a timer are now handled as an unsigned integer value
Diffstat (limited to 'timers.c')
-rw-r--r--timers.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/timers.c b/timers.c
index 5ad4cbee..144f0d6a 100644
--- a/timers.c
+++ b/timers.c
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: timers.c 1.39 2006/01/03 11:45:19 kls Exp $
+ * $Id: timers.c 1.40 2006/01/06 14:14:59 kls Exp $
*/
#include "timers.h"
@@ -110,7 +110,7 @@ cString cTimer::ToText(bool UseChannelID)
char *buffer;
strreplace(file, ':', '|');
strreplace(summary, '\n', '|');
- asprintf(&buffer, "%d:%s:%s:%04d:%04d:%d:%d:%s:%s\n", flags, UseChannelID ? *Channel()->GetChannelID().ToString() : *itoa(Channel()->Number()), *PrintDay(day, weekdays), start, stop, priority, lifetime, file, summary ? summary : "");
+ asprintf(&buffer, "%u:%s:%s:%04d:%04d:%d:%d:%s:%s\n", flags, UseChannelID ? *Channel()->GetChannelID().ToString() : *itoa(Channel()->Number()), *PrintDay(day, weekdays), start, stop, priority, lifetime, file, summary ? summary : "");
strreplace(summary, '|', '\n');
strreplace(file, '|', ':');
return cString(buffer, true);
@@ -244,7 +244,7 @@ bool cTimer::Parse(const char *s)
s = s2;
}
bool result = false;
- if (8 <= sscanf(s, "%d :%a[^:]:%a[^:]:%d :%d :%d :%d :%a[^:\n]:%a[^\n]", &flags, &channelbuffer, &daybuffer, &start, &stop, &priority, &lifetime, &filebuffer, &summary)) {
+ if (8 <= sscanf(s, "%u :%a[^:]:%a[^:]:%d :%d :%d :%d :%a[^:\n]:%a[^\n]", &flags, &channelbuffer, &daybuffer, &start, &stop, &priority, &lifetime, &filebuffer, &summary)) {
if (summary && !*skipspace(summary)) {
free(summary);
summary = NULL;
@@ -467,22 +467,22 @@ void cTimer::SetPriority(int Priority)
priority = Priority;
}
-void cTimer::SetFlags(int Flags)
+void cTimer::SetFlags(uint Flags)
{
flags |= Flags;
}
-void cTimer::ClrFlags(int Flags)
+void cTimer::ClrFlags(uint Flags)
{
flags &= ~Flags;
}
-void cTimer::InvFlags(int Flags)
+void cTimer::InvFlags(uint Flags)
{
flags ^= Flags;
}
-bool cTimer::HasFlags(int Flags) const
+bool cTimer::HasFlags(uint Flags) const
{
return (flags & Flags) == Flags;
}