C: Fixes for sign compares in C libraries

Added explicit error for sign compares to CMake.  Updated a handful of C
source which compared unsigned vs signed.

Signed-off-by: Noel Eck <noel.eck@intel.com>
This commit is contained in:
Noel Eck
2018-02-07 12:17:54 -08:00
parent 460fdc2eb5
commit fe7bd75c91
14 changed files with 21 additions and 24 deletions

View File

@ -303,7 +303,7 @@ upm_result_t m24lr64e_eeprom_write_bytes(m24lr64e_context dev,
upm_result_t m24lr64e_eeprom_read_byte(m24lr64e_context dev, uint32_t address,
uint8_t* data){
uint32_t pkt_len = 2;
int pkt_len = 2;
uint8_t buf[pkt_len];
buf[0] = ((address >> 8) & 0xff);