compilation: Add -Wconversion to more files and validate CONV_SOURCES

All files under the os, api and msgpack_rpc directories have -Wconversion
automatically applied. CONV_SOURCES is also checked for missing files(when
renaming, for example)
This commit is contained in:
Thiago de Arruda
2014-10-21 08:53:55 -03:00
parent cf9571b7b1
commit 79b7263f79
6 changed files with 61 additions and 60 deletions

View File

@@ -119,7 +119,8 @@ int server_start(const char *endpoint)
ip_end = strchr(addr, NUL);
}
uint32_t addr_len = ip_end - addr;
// (ip_end - addr) is always > 0, so convert to size_t
size_t addr_len = (size_t)(ip_end - addr);
if (addr_len > sizeof(ip) - 1) {
// Maximum length of an IP address buffer is 15(eg: 255.255.255.255)