summaryrefslogtreecommitdiff
path: root/apps/plugins/calendar.c
diff options
context:
space:
mode:
authorJens Arnold <amiconn@rockbox.org>2007-03-16 23:47:03 +0000
committerJens Arnold <amiconn@rockbox.org>2007-03-16 23:47:03 +0000
commit2c7b127dd77564a8ca8c384d7d1abed441efe110 (patch)
tree95353f6db63c676890176f26fb9f452e8050d547 /apps/plugins/calendar.c
parentc0351ca6338075461565b7ba14b01ba3cabb3f1e (diff)
downloadrockbox-2c7b127dd77564a8ca8c384d7d1abed441efe110.zip
rockbox-2c7b127dd77564a8ca8c384d7d1abed441efe110.tar.gz
rockbox-2c7b127dd77564a8ca8c384d7d1abed441efe110.tar.bz2
rockbox-2c7b127dd77564a8ca8c384d7d1abed441efe110.tar.xz
Set CONFIG_RTC to 0 for non-RTC targets, and check with #if to profit from -Wundef. No code change.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@12811 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/plugins/calendar.c')
-rw-r--r--apps/plugins/calendar.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/apps/plugins/calendar.c b/apps/plugins/calendar.c
index 34af474..8c0b6af 100644
--- a/apps/plugins/calendar.c
+++ b/apps/plugins/calendar.c
@@ -19,7 +19,7 @@
****************************************************************************/
#include "plugin.h"
-#if defined(HAVE_LCD_BITMAP) && defined(CONFIG_RTC)
+#if defined(HAVE_LCD_BITMAP) && (CONFIG_RTC != 0)
#include <timefuncs.h>
@@ -71,7 +71,7 @@ static int calc_weekday( struct shown *shown )
static void calendar_init(struct today *today, struct shown *shown)
{
int w,h;
-#ifdef CONFIG_RTC
+#if CONFIG_RTC
struct tm *tm;
#else
(void)today;
@@ -83,7 +83,7 @@ static void calendar_init(struct today *today, struct shown *shown)
use_system_font = true;
}
rb->lcd_clear_display();
-#ifdef CONFIG_RTC
+#if CONFIG_RTC
tm = rb->get_time();
today->mon = tm->tm_mon +1;
today->year = 2000+tm->tm_year%100;