diff options
author | Thomas Martitz <kugel@rockbox.org> | 2010-05-06 21:04:40 +0000 |
---|---|---|
committer | Thomas Martitz <kugel@rockbox.org> | 2010-05-06 21:04:40 +0000 |
commit | 50a6ca39ad4ed01922aa4f755f0ca579788226cf (patch) | |
tree | c7881b015b220558167310345b162324c96be15a /apps/replaygain.c | |
parent | adb506df14aded06ed6e9ebf8540e6fd383ffd6a (diff) | |
download | rockbox-50a6ca39ad4ed01922aa4f755f0ca579788226cf.tar.gz rockbox-50a6ca39ad4ed01922aa4f755f0ca579788226cf.zip |
Move c/h files implementing/defining standard library stuff into a new libc directory, also standard'ify some parts of the code base (almost entirely #include fixes).
This is to a) to cleanup firmware/common and firmware/include a bit, but also b) for Rockbox as an application which should use the host system's c library and headers, separating makes it easy to exclude our files from the build.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25850 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/replaygain.c')
-rw-r--r-- | apps/replaygain.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/apps/replaygain.c b/apps/replaygain.c index 6ece1104b4..81f1a45ad7 100644 --- a/apps/replaygain.c +++ b/apps/replaygain.c | |||
@@ -20,13 +20,14 @@ | |||
20 | ****************************************************************************/ | 20 | ****************************************************************************/ |
21 | 21 | ||
22 | #include <ctype.h> | 22 | #include <ctype.h> |
23 | #include <inttypes.h> | ||
24 | #include <math.h> | 23 | #include <math.h> |
25 | #include <stdbool.h> | 24 | #include <stdbool.h> |
26 | #include <stdio.h> | 25 | #include <stdio.h> |
27 | #include <stdlib.h> | 26 | #include <stdlib.h> |
28 | #include <string.h> | 27 | #include <inttypes.h> |
29 | #include <system.h> | 28 | #include "strlcpy.h" |
29 | #include "strcasecmp.h" | ||
30 | #include "system.h" | ||
30 | #include "metadata.h" | 31 | #include "metadata.h" |
31 | #include "debug.h" | 32 | #include "debug.h" |
32 | #include "replaygain.h" | 33 | #include "replaygain.h" |
@@ -244,7 +245,7 @@ long parse_replaygain_int(bool album, long gain, long peak, | |||
244 | 245 | ||
245 | if (buffer != NULL) | 246 | if (buffer != NULL) |
246 | { | 247 | { |
247 | len = snprintf(buffer, length, "%d.%02d dB", gain / 512, | 248 | len = snprintf(buffer, length, "%ld.%02d dB", gain / 512, |
248 | ((abs(gain) & 0x01ff) * 100 + 256) / 512); | 249 | ((abs(gain) & 0x01ff) * 100 + 256) / 512); |
249 | len++; | 250 | len++; |
250 | } | 251 | } |