code sanitizations (compiler warnings)

This commit is contained in:
Verkehrsrot 2019-10-13 17:22:30 +02:00
parent e94c73295b
commit 88f40e5d35
2 changed files with 5 additions and 2 deletions

View File

@ -450,7 +450,7 @@ void myEventCallback(void *pUserData, ev_t ev) {
snprintf(lmic_event_msg, LMIC_EVENTMSG_LEN, "%-16s", snprintf(lmic_event_msg, LMIC_EVENTMSG_LEN, "%-16s",
evNames[ev] + 3); // +3 to strip "EV_" evNames[ev] + 3); // +3 to strip "EV_"
else else
snprintf(lmic_event_msg, LMIC_EVENTMSG_LEN, "LMIC event %-04u ", ev); snprintf(lmic_event_msg, LMIC_EVENTMSG_LEN, "LMIC event %-4u ", ev);
// process current event message // process current event message
switch (ev) { switch (ev) {
@ -468,6 +468,9 @@ void myEventCallback(void *pUserData, ev_t ev) {
// replace descriptor from library with more descriptive term // replace descriptor from library with more descriptive term
snprintf(lmic_event_msg, LMIC_EVENTMSG_LEN, "%-16s", "JOIN_WAIT"); snprintf(lmic_event_msg, LMIC_EVENTMSG_LEN, "%-16s", "JOIN_WAIT");
break; break;
default:
break;
} }
// add Lora send queue length to display // add Lora send queue length to display

View File

@ -194,7 +194,7 @@ int recv_timesync_ans(const uint8_t buf[], const uint8_t buf_len) {
uint32_t timestamp_sec, *timestamp_ptr; uint32_t timestamp_sec, *timestamp_ptr;
// extract 1 byte timezone from buffer (one step being 15min * 60s = 900s) // extract 1 byte timezone from buffer (one step being 15min * 60s = 900s)
uint32_t timezone_sec = buf[0] * 900; // uint32_t timezone_sec = buf[0] * 900; // for future use
buf++; buf++;
// extract 4 bytes timestamp from buffer // extract 4 bytes timestamp from buffer