summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJean-Philippe Bernardy <jeanphilippe.bernardy@gmail.com>2005-02-11 18:41:40 +0000
committerJean-Philippe Bernardy <jeanphilippe.bernardy@gmail.com>2005-02-11 18:41:40 +0000
commit2860c5e70ae6c4ded2a662b8eed5996e381ed014 (patch)
tree50292902d4ab7dfb64447cfbf861acc3df04a153
parent6dca87e60cb54073c5a0b26b233bfc239b763d6b (diff)
downloadrockbox-2860c5e70ae6c4ded2a662b8eed5996e381ed014.zip
rockbox-2860c5e70ae6c4ded2a662b8eed5996e381ed014.tar.gz
rockbox-2860c5e70ae6c4ded2a662b8eed5996e381ed014.tar.bz2
rockbox-2860c5e70ae6c4ded2a662b8eed5996e381ed014.tar.xz
long policy
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@5914 a1c6a512-1295-4272-9138-f99709370657
-rw-r--r--apps/main_menu.c2
-rw-r--r--apps/settings.c19
-rw-r--r--firmware/mpeg.c6
3 files changed, 14 insertions, 13 deletions
diff --git a/apps/main_menu.c b/apps/main_menu.c
index a2694ad..ff09568 100644
--- a/apps/main_menu.c
+++ b/apps/main_menu.c
@@ -139,7 +139,7 @@ bool show_info(void)
{
char s[32], s2[32];
/* avoid overflow for 8MB mod :) was: ((mp3end - mp3buf) * 1000) / 0x100000; */
- int buflen = ((mp3end - mp3buf) * 100) / 0x19999;
+ long buflen = ((mp3end - mp3buf) * 100) / 0x19999;
int integer, decimal;
bool done = false;
int key;
diff --git a/apps/settings.c b/apps/settings.c
index 4bda34b..6bc7e96 100644
--- a/apps/settings.c
+++ b/apps/settings.c
@@ -82,7 +82,7 @@ const char rec_base_directory[] = REC_BASE_DIR;
#endif
long lasttime = 0;
-static int config_sector = 0; /* mark uninitialized */
+static long config_sector = 0; /* mark uninitialized */
static unsigned char config_block[CONFIG_BLOCK_SIZE];
@@ -629,8 +629,9 @@ void settings_calc_config_sector(void)
#ifdef SIMULATOR
config_sector = 61;
#else
- int i, partition_start;
- int sector = 0;
+ int i;
+ long partition_start;
+ long sector = 0;
if (fat_startsector(IF_MV(0)) != 0) /* There is a partition table */
{
@@ -1333,7 +1334,7 @@ bool set_int(const char* string,
bool done = false;
int button;
int org_value=*variable;
- int last_value = 0x7FFFFFFF; /* out of range init */
+ int last_value = __INT_MAX__; /* out of range init */
#ifdef HAVE_LCD_BITMAP
if(global_settings.statusbar)
@@ -1538,7 +1539,7 @@ bool set_option(const char* string, void* variable, enum optiontype type,
/* This array holds the record timer interval lengths, in seconds */
static const unsigned long rec_timer_seconds[] =
{
- 24*60*60, /* OFF really means 24 hours, to avoid >2Gbyte files */
+ 24L*60*60, /* OFF really means 24 hours, to avoid >2Gbyte files */
5*60, /* 00:05 */
10*60, /* 00:10 */
15*60, /* 00:15 */
@@ -1550,10 +1551,10 @@ static const unsigned long rec_timer_seconds[] =
4*60*60, /* 04:00 */
6*60*60, /* 06:00 */
8*60*60, /* 08:00 */
- 10*60*60, /* 10:00 */
- 12*60*60, /* 12:00 */
- 18*60*60, /* 18:00 */
- 24*60*60 /* 24:00 */
+ 10L*60*60, /* 10:00 */
+ 12L*60*60, /* 12:00 */
+ 18L*60*60, /* 18:00 */
+ 24L*60*60 /* 24:00 */
};
unsigned int rec_timesplit_seconds(void)
diff --git a/firmware/mpeg.c b/firmware/mpeg.c
index 3223cab..e2bb75a 100644
--- a/firmware/mpeg.c
+++ b/firmware/mpeg.c
@@ -326,9 +326,9 @@ static bool is_playing; /* We are (attempting to) playing MP3 files */
static bool filling; /* We are filling the buffer with data from disk */
static bool dma_underrun; /* True when the DMA has stopped because of
slow disk reading (read error, shaking) */
-static int low_watermark; /* Dynamic low watermark level */
-static int low_watermark_margin; /* Extra time in seconds for watermark */
-static int lowest_watermark_level; /* Debug value to observe the buffer
+static long low_watermark; /* Dynamic low watermark level */
+static long low_watermark_margin; /* Extra time in seconds for watermark */
+static long lowest_watermark_level; /* Debug value to observe the buffer
usage */
#if CONFIG_HWCODEC == MAS3587F
static bool is_recording; /* We are recording */