Fix a few -Wconversion warnings (there are many more to do)

This commit is contained in:
Dirk Ziegelmeier
2016-12-19 11:52:19 +01:00
parent be57134810
commit dd96c71253
10 changed files with 17 additions and 17 deletions

View File

@@ -715,7 +715,7 @@ netif_found:
options_done:
/* p points to IPv6 header again. */
pbuf_header_force(p, ip_data.current_ip_header_tot_len);
pbuf_header_force(p, (s16_t)ip_data.current_ip_header_tot_len);
/* send to upper layers */
LWIP_DEBUGF(IP6_DEBUG, ("ip6_input: \n"));

View File

@@ -132,8 +132,8 @@ ip6addr_aton(const char *cp, ip6_addr_t *addr)
} else if (isxdigit(*s)) {
/* add current digit */
current_block_value = (current_block_value << 4) +
(isdigit(*s) ? *s - '0' :
10 + (islower(*s) ? *s - 'a' : *s - 'A'));
(isdigit(*s) ? (u32_t)(*s - '0') :
(u32_t)(10 + (islower(*s) ? *s - 'a' : *s - 'A')));
} else {
/* unexpected digit, space? CRLF? */
break;