From: Andre Noll Date: Wed, 28 Dec 2016 19:38:34 +0000 (+0100) Subject: Merge branch 'refs/heads/t/format-signedness' X-Git-Tag: v0.5.7~6 X-Git-Url: http://git.tuebingen.mpg.de/?p=paraslash.git;a=commitdiff_plain;h=b52342d0b5df5446f149f0c1daf26f6e25b2aba7 Merge branch 'refs/heads/t/format-signedness' This series fixes all warnings produced by compiling with -Wformat-signedness and adds the flag to CFLAGS if the compiler supports it. * refs/heads/t/format-signedness (cooking for ~2 weeks): gcrypt: Fix a few format-signedness issues. Compile with -Wformat-signedness if possible. Fix signedness issues in format strings. --- b52342d0b5df5446f149f0c1daf26f6e25b2aba7 diff --cc NEWS.md index 10e78ca5,71eb6cb2..a7af7717 --- a/NEWS.md +++ b/NEWS.md @@@ -1,22 -1,6 +1,23 @@@ NEWS ==== +------------------------------------------ +0.5.7 (to be announced) "semantic density" +------------------------------------------ +- Speedup of the base64 decoder. +- One of the two source browsers has been removed from the web pages. + The doxygen API reference still contains an HTML version of each + source file. +- Two race conditions in para_server have been fixed. +- ls -p is now deprecated in favor of -F or -b. See the help text of + the ls command for details. +- The openssl code has been adjusted to work also with openssl-1.1. +- The wma decoder and audio format handler now correctly decodes + files with unusual block sizes. ++- We now compile with -Wformat-signedness if possible. + +Download: [tarball](./releases/paraslash-git.tar.bz2) + --------------------------------------- 0.5.6 (2016-07-10) "cascading gradient" --------------------------------------- diff --cc aac_afh.c index a30be96f,bcd2a14e..1c7fd706 --- a/aac_afh.c +++ b/aac_afh.c @@@ -33,12 -32,12 +33,12 @@@ static int aac_find_stsz(char *buf, siz continue; PARA_DEBUG_LOG("found stsz@%d\n", i); i += 8; - sample_size = aac_read_int32(buf + i); + sample_size = read_u32_be(buf + i); - PARA_DEBUG_LOG("sample size: %d\n", sample_size); + PARA_DEBUG_LOG("sample size: %u\n", sample_size); i += 4; - sample_count = aac_read_int32(buf + i); + sample_count = read_u32_be(buf + i); i += 4; - PARA_DEBUG_LOG("sample count: %d\n", sample_count); + PARA_DEBUG_LOG("sample count: %u\n", sample_count); *skip = i; return sample_count; } diff --cc aac_common.c index 70a9d77d,fe9b7295..812c742c --- a/aac_common.c +++ b/aac_common.c @@@ -73,18 -72,18 +73,18 @@@ int aac_find_esds(char *buf, size_t buf continue; i += 8; p = buf + i; -- PARA_INFO_LOG("found esds@%zu, next: %x\n", i, *p); ++ PARA_INFO_LOG("found esds@%zu, next: %x\n", i, (unsigned)*p); if (*p == 3) i += 8; else i += 6; p = buf + i; -- PARA_INFO_LOG("next: %x\n", *p); ++ PARA_INFO_LOG("next: %x\n", (unsigned)*p); if (*p != 4) continue; i += 18; p = buf + i; -- PARA_INFO_LOG("next: %x\n", *p); ++ PARA_INFO_LOG("next: %x\n", (unsigned)*p); if (*p != 5) continue; i++; diff --cc wma_common.c index 27cb51d0,95bb9ace..6d57c00b --- a/wma_common.c +++ b/wma_common.c @@@ -42,17 -42,6 +42,17 @@@ const char *search_pattern(const char * return NULL; } +static int find_file_properties(const char *buf, int len) +{ + const char pattern[] = {0xa1, 0xdc, 0xab, 0x8c}; + const char *p = search_pattern(pattern, sizeof(pattern), buf, len); + + if (!p) + return -E_WMA_NO_GUID; - PARA_DEBUG_LOG("found file property guid@%0x\n", (int)(p - buf)); ++ PARA_DEBUG_LOG("found file property guid@%0x\n", (unsigned)(p - buf)); + return p - buf + 16; +} + /* 40 9e 69 f8 4d 5b cf 11 a8 fd 00 80 5f 5c 44 2b */ @@@ -118,7 -107,7 +118,7 @@@ int read_asf_header(const char *buf, in ahi->flags1 = read_u32(start + 56); ahi->flags2 = read_u16(start + 60); - PARA_INFO_LOG("read_asf_header: flags1: %d, flags2: %d\n", - PARA_INFO_LOG("read_asf_header: flags1: %u, flag2: %u\n", ++ PARA_INFO_LOG("read_asf_header: flags1: %u, flags2: %u\n", ahi->flags1, ahi->flags2); ahi->use_exp_vlc = ahi->flags2 & 0x0001; ahi->use_bit_reservoir = ahi->flags2 & 0x0002;