Fix compilation warnings (apart from nanostack)

pull/9208/head
Michal Paszta 2018-11-23 10:07:32 +01:00 committed by Cruz Monrreal II
parent da0a385f7d
commit 1931c2cd27
5 changed files with 5 additions and 4 deletions

View File

@ -101,7 +101,7 @@ void rf_conf_calculate_rx_filter_bandwidth_registers(uint32_t rx_bandwidth, uint
uint8_t chflt_e_tmp = 0; uint8_t chflt_e_tmp = 0;
uint8_t chflt_m_tmp = 0; uint8_t chflt_m_tmp = 0;
while (rx_bandwidth < 900000 / (2 << chflt_e_tmp)) { while (rx_bandwidth < 900000u / (2 << chflt_e_tmp)) {
chflt_e_tmp++; chflt_e_tmp++;
} }
uint32_t rx_bandwidth_tmp = rx_bandwidth; uint32_t rx_bandwidth_tmp = rx_bandwidth;

View File

@ -791,7 +791,7 @@ int SDBlockDevice::_cmd(SDBlockDevice::cmdSupported cmd, uint32_t arg, bool isAc
switch (cmd) { switch (cmd) {
case CMD8_SEND_IF_COND: // Response R7 case CMD8_SEND_IF_COND: // Response R7
debug_if(_dbg, "V2-Version Card\n"); debug_if(_dbg, "V2-Version Card\n");
_card_type = SDCARD_V2; _card_type = SDCARD_V2; // fallthrough
// Note: No break here, need to read rest of the response // Note: No break here, need to read rest of the response
case CMD58_READ_OCR: // Response R3 case CMD58_READ_OCR: // Response R3
response = (_spi.write(SPI_FILL_CHAR) << 24); response = (_spi.write(SPI_FILL_CHAR) << 24);

View File

@ -467,7 +467,7 @@ ssize_t ATHandler::read_string(char *buf, size_t size, bool read_even_stop_tag)
return -1; return -1;
} }
int len = 0; unsigned int len = 0;
size_t match_pos = 0; size_t match_pos = 0;
bool delimiter_found = false; bool delimiter_found = false;

View File

@ -27,6 +27,7 @@
#include "multicast_api.h" #include "multicast_api.h"
#include "mac_api.h" #include "mac_api.h"
#include "sw_mac.h" #include "sw_mac.h"
#include "ws_management_api.h" //ws_management_node_init
// For tracing we need to define flag, have include and define group // For tracing we need to define flag, have include and define group
//#define HAVE_DEBUG //#define HAVE_DEBUG

View File

@ -59,7 +59,7 @@ void mbed_error_vprintf(const char *format, va_list arg)
{ {
char buffer[132]; char buffer[132];
int size = vsnprintf(buffer, sizeof buffer, format, arg); int size = vsnprintf(buffer, sizeof buffer, format, arg);
if (size >= sizeof buffer) { if ((unsigned int)size >= sizeof buffer) {
/* Output was truncated - indicate by overwriting tail of buffer /* Output was truncated - indicate by overwriting tail of buffer
* with ellipsis, newline and null terminator. * with ellipsis, newline and null terminator.
*/ */