diff options
author | Magnus Holmgren <magnushol@gmail.com> | 2007-03-18 09:50:53 +0000 |
---|---|---|
committer | Magnus Holmgren <magnushol@gmail.com> | 2007-03-18 09:50:53 +0000 |
commit | 01a010fd19a64f150ea95f223b1fd209c378ae57 (patch) | |
tree | 40353423740b16e74e1128a283ea882f50bc8710 /apps | |
parent | dd40a2e2fcde145cd6a70a1042729032e4da26f3 (diff) | |
download | rockbox-01a010fd19a64f150ea95f223b1fd209c378ae57.tar.gz rockbox-01a010fd19a64f150ea95f223b1fd209c378ae57.zip |
Fix several printf-style warnings in logf builds.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@12830 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps')
-rw-r--r-- | apps/codecs/alac.c | 2 | ||||
-rw-r--r-- | apps/codecs/flac.c | 2 | ||||
-rw-r--r-- | apps/codecs/shorten.c | 2 | ||||
-rw-r--r-- | apps/tagcache.c | 22 | ||||
-rw-r--r-- | apps/tagtree.c | 14 |
5 files changed, 21 insertions, 21 deletions
diff --git a/apps/codecs/alac.c b/apps/codecs/alac.c index ca62538a66..bedd2dd581 100644 --- a/apps/codecs/alac.c +++ b/apps/codecs/alac.c | |||
@@ -136,7 +136,7 @@ enum codec_status codec_main(void) | |||
136 | retval = CODEC_OK; | 136 | retval = CODEC_OK; |
137 | 137 | ||
138 | done: | 138 | done: |
139 | LOGF("ALAC: Decoded %d samples\n",samplesdone); | 139 | LOGF("ALAC: Decoded %ld samples\n",samplesdone); |
140 | 140 | ||
141 | if (ci->request_next_track()) | 141 | if (ci->request_next_track()) |
142 | goto next_track; | 142 | goto next_track; |
diff --git a/apps/codecs/flac.c b/apps/codecs/flac.c index 00e0a1f242..2eb0deb9f5 100644 --- a/apps/codecs/flac.c +++ b/apps/codecs/flac.c | |||
@@ -506,7 +506,7 @@ enum codec_status codec_main(void) | |||
506 | retval = CODEC_OK; | 506 | retval = CODEC_OK; |
507 | 507 | ||
508 | done: | 508 | done: |
509 | LOGF("FLAC: Decoded %d samples\n",samplesdone); | 509 | LOGF("FLAC: Decoded %ld samples\n",samplesdone); |
510 | 510 | ||
511 | if (ci->request_next_track()) | 511 | if (ci->request_next_track()) |
512 | goto next_track; | 512 | goto next_track; |
diff --git a/apps/codecs/shorten.c b/apps/codecs/shorten.c index 004a4070bd..4b803675f9 100644 --- a/apps/codecs/shorten.c +++ b/apps/codecs/shorten.c | |||
@@ -130,7 +130,7 @@ seek_start: | |||
130 | bytesleft, ci->yield); | 130 | bytesleft, ci->yield); |
131 | 131 | ||
132 | if (res == FN_ERROR) { | 132 | if (res == FN_ERROR) { |
133 | LOGF("Shorten: shorten_decode_frames error (%d)\n", samplesdone); | 133 | LOGF("Shorten: shorten_decode_frames error (%ld)\n", samplesdone); |
134 | break; | 134 | break; |
135 | } else { | 135 | } else { |
136 | /* Insert decoded samples in pcmbuf */ | 136 | /* Insert decoded samples in pcmbuf */ |
diff --git a/apps/tagcache.c b/apps/tagcache.c index 0ddf2b0228..3a8e73599b 100644 --- a/apps/tagcache.c +++ b/apps/tagcache.c | |||
@@ -1568,7 +1568,7 @@ static void add_tagcache(char *path) | |||
1568 | if (path_length > TAG_MAXLEN) | 1568 | if (path_length > TAG_MAXLEN) |
1569 | { | 1569 | { |
1570 | /* Path can't be shortened. */ | 1570 | /* Path can't be shortened. */ |
1571 | logf("Too long path: %s"); | 1571 | logf("Too long path: %s", path); |
1572 | return ; | 1572 | return ; |
1573 | } | 1573 | } |
1574 | 1574 | ||
@@ -1974,7 +1974,7 @@ static bool build_numeric_indices(struct tagcache_header *h, int tmpfd) | |||
1974 | } | 1974 | } |
1975 | 1975 | ||
1976 | entries_processed += count; | 1976 | entries_processed += count; |
1977 | logf("%d/%d entries processed", entries_processed, h->entry_count); | 1977 | logf("%d/%ld entries processed", entries_processed, h->entry_count); |
1978 | } | 1978 | } |
1979 | 1979 | ||
1980 | close(masterfd); | 1980 | close(masterfd); |
@@ -2019,7 +2019,7 @@ static int build_index(int index_type, struct tagcache_header *h, int tmpfd) | |||
2019 | fd = open_tag_fd(&tch, index_type, true); | 2019 | fd = open_tag_fd(&tch, index_type, true); |
2020 | if (fd >= 0) | 2020 | if (fd >= 0) |
2021 | { | 2021 | { |
2022 | logf("tch.datasize=%d", tch.datasize); | 2022 | logf("tch.datasize=%ld", tch.datasize); |
2023 | lookup_buffer_depth = 1 + | 2023 | lookup_buffer_depth = 1 + |
2024 | /* First part */ commit_entry_count + | 2024 | /* First part */ commit_entry_count + |
2025 | /* Second part */ (tch.datasize / TAGFILE_ENTRY_CHUNK_LENGTH); | 2025 | /* Second part */ (tch.datasize / TAGFILE_ENTRY_CHUNK_LENGTH); |
@@ -2031,8 +2031,8 @@ static int build_index(int index_type, struct tagcache_header *h, int tmpfd) | |||
2031 | /* Second part */ 0; | 2031 | /* Second part */ 0; |
2032 | } | 2032 | } |
2033 | 2033 | ||
2034 | logf("lookup_buffer_depth=%d", lookup_buffer_depth); | 2034 | logf("lookup_buffer_depth=%ld", lookup_buffer_depth); |
2035 | logf("commit_entry_count=%d", commit_entry_count); | 2035 | logf("commit_entry_count=%ld", commit_entry_count); |
2036 | 2036 | ||
2037 | /* Allocate buffer for all index entries from both old and new | 2037 | /* Allocate buffer for all index entries from both old and new |
2038 | * tag files. */ | 2038 | * tag files. */ |
@@ -2322,7 +2322,7 @@ static int build_index(int index_type, struct tagcache_header *h, int tmpfd) | |||
2322 | 2322 | ||
2323 | if (idxbuf[j].tag_seek[index_type] < 0) | 2323 | if (idxbuf[j].tag_seek[index_type] < 0) |
2324 | { | 2324 | { |
2325 | logf("update error: %d/%d", i+j, tcmh.tch.entry_count); | 2325 | logf("update error: %d/%ld", i+j, tcmh.tch.entry_count); |
2326 | error = true; | 2326 | error = true; |
2327 | goto error_exit; | 2327 | goto error_exit; |
2328 | } | 2328 | } |
@@ -2405,7 +2405,7 @@ static int build_index(int index_type, struct tagcache_header *h, int tmpfd) | |||
2405 | entry.tag_length[index_type]) | 2405 | entry.tag_length[index_type]) |
2406 | { | 2406 | { |
2407 | logf("read fail #8"); | 2407 | logf("read fail #8"); |
2408 | logf("offset=0x%02x", entry.tag_offset[index_type]); | 2408 | logf("offset=0x%02lx", entry.tag_offset[index_type]); |
2409 | logf("length=0x%02x", entry.tag_length[index_type]); | 2409 | logf("length=0x%02x", entry.tag_length[index_type]); |
2410 | error = true; | 2410 | error = true; |
2411 | break ; | 2411 | break ; |
@@ -2459,7 +2459,7 @@ static int build_index(int index_type, struct tagcache_header *h, int tmpfd) | |||
2459 | 2459 | ||
2460 | if (index_type != tag_filename) | 2460 | if (index_type != tag_filename) |
2461 | h->datasize += tch.datasize; | 2461 | h->datasize += tch.datasize; |
2462 | logf("s:%d/%d/%d", index_type, tch.datasize, h->datasize); | 2462 | logf("s:%d/%ld/%ld", index_type, tch.datasize, h->datasize); |
2463 | error_exit: | 2463 | error_exit: |
2464 | 2464 | ||
2465 | close(fd); | 2465 | close(fd); |
@@ -2564,7 +2564,7 @@ static bool commit(void) | |||
2564 | return false; | 2564 | return false; |
2565 | } | 2565 | } |
2566 | 2566 | ||
2567 | logf("commit %d entries...", tch.entry_count); | 2567 | logf("commit %ld entries...", tch.entry_count); |
2568 | 2568 | ||
2569 | /* Mark DB dirty so it will stay disabled if commit fails. */ | 2569 | /* Mark DB dirty so it will stay disabled if commit fails. */ |
2570 | current_tcmh.dirty = true; | 2570 | current_tcmh.dirty = true; |
@@ -3050,7 +3050,7 @@ static bool delete_entry(long idx_id) | |||
3050 | char buf[TAG_MAXLEN+32]; | 3050 | char buf[TAG_MAXLEN+32]; |
3051 | int in_use[TAG_COUNT]; | 3051 | int in_use[TAG_COUNT]; |
3052 | 3052 | ||
3053 | logf("delete_entry(): %d", idx_id); | 3053 | logf("delete_entry(): %ld", idx_id); |
3054 | 3054 | ||
3055 | #ifdef HAVE_TC_RAMCACHE | 3055 | #ifdef HAVE_TC_RAMCACHE |
3056 | /* At first mark the entry removed from ram cache. */ | 3056 | /* At first mark the entry removed from ram cache. */ |
@@ -3482,7 +3482,7 @@ static bool load_tagcache(void) | |||
3482 | { | 3482 | { |
3483 | logf("too big tagcache #2"); | 3483 | logf("too big tagcache #2"); |
3484 | logf("tl: %d", fe->tag_length); | 3484 | logf("tl: %d", fe->tag_length); |
3485 | logf("bl: %d", bytesleft); | 3485 | logf("bl: %ld", bytesleft); |
3486 | close(fd); | 3486 | close(fd); |
3487 | return false; | 3487 | return false; |
3488 | } | 3488 | } |
diff --git a/apps/tagtree.c b/apps/tagtree.c index fadeeb52e1..33c36b7b83 100644 --- a/apps/tagtree.c +++ b/apps/tagtree.c | |||
@@ -645,7 +645,7 @@ static void tagtree_unbuffer_event(struct mp3entry *id3, bool last_track) | |||
645 | lastplayed = tagcache_increase_serial(); | 645 | lastplayed = tagcache_increase_serial(); |
646 | if (lastplayed < 0) | 646 | if (lastplayed < 0) |
647 | { | 647 | { |
648 | logf("incorrect tc serial:%d", lastplayed); | 648 | logf("incorrect tc serial:%ld", lastplayed); |
649 | tagcache_search_finish(&tcs); | 649 | tagcache_search_finish(&tcs); |
650 | return; | 650 | return; |
651 | } | 651 | } |
@@ -654,8 +654,8 @@ static void tagtree_unbuffer_event(struct mp3entry *id3, bool last_track) | |||
654 | playtime += MIN(id3->length, id3->elapsed + 15 * 1000); | 654 | playtime += MIN(id3->length, id3->elapsed + 15 * 1000); |
655 | 655 | ||
656 | logf("ube:%s", id3->path); | 656 | logf("ube:%s", id3->path); |
657 | logf("-> %d/%d/%d", last_track, playcount, playtime); | 657 | logf("-> %d/%ld/%ld", last_track, playcount, playtime); |
658 | logf("-> %d/%d/%d", id3->elapsed, id3->length, MIN(id3->length, id3->elapsed + 15 * 1000)); | 658 | logf("-> %ld/%ld/%ld", id3->elapsed, id3->length, MIN(id3->length, id3->elapsed + 15 * 1000)); |
659 | 659 | ||
660 | /* lastplayed not yet supported. */ | 660 | /* lastplayed not yet supported. */ |
661 | 661 | ||
@@ -750,7 +750,7 @@ static int parse_line(int n, const char *buf, void *parameters) | |||
750 | case var_include: | 750 | case var_include: |
751 | if (get_token_str(data, sizeof(data)) < 0) | 751 | if (get_token_str(data, sizeof(data)) < 0) |
752 | { | 752 | { |
753 | logf("%include empty"); | 753 | logf("%%include empty"); |
754 | return 0; | 754 | return 0; |
755 | } | 755 | } |
756 | 756 | ||
@@ -772,12 +772,12 @@ static int parse_line(int n, const char *buf, void *parameters) | |||
772 | memset(menu, 0, sizeof(struct root_menu)); | 772 | memset(menu, 0, sizeof(struct root_menu)); |
773 | if (get_token_str(menu->id, sizeof(menu->id)) < 0) | 773 | if (get_token_str(menu->id, sizeof(menu->id)) < 0) |
774 | { | 774 | { |
775 | logf("%menu_start id empty"); | 775 | logf("%%menu_start id empty"); |
776 | return 0; | 776 | return 0; |
777 | } | 777 | } |
778 | if (get_token_str(menu->title, sizeof(menu->title)) < 0) | 778 | if (get_token_str(menu->title, sizeof(menu->title)) < 0) |
779 | { | 779 | { |
780 | logf("%menu_start title empty"); | 780 | logf("%%menu_start title empty"); |
781 | return 0; | 781 | return 0; |
782 | } | 782 | } |
783 | logf("menu: %s", menu->title); | 783 | logf("menu: %s", menu->title); |
@@ -792,7 +792,7 @@ static int parse_line(int n, const char *buf, void *parameters) | |||
792 | 792 | ||
793 | if (get_token_str(data, sizeof(data)) < 0) | 793 | if (get_token_str(data, sizeof(data)) < 0) |
794 | { | 794 | { |
795 | logf("%root_menu empty"); | 795 | logf("%%root_menu empty"); |
796 | return 0; | 796 | return 0; |
797 | } | 797 | } |
798 | 798 | ||