Fix signedness comparison for ESP8266 compiler
This commit is contained in:
@ -240,7 +240,7 @@ bool timespec_get_spec(struct mgos_timespec *ts, char *ret, int retlen) {
|
|||||||
|
|
||||||
snprintf(spec_str, sizeof(spec_str) - 1, "%02d:%02d:%02d-%02d:%02d:%02d", t_spec->start_h, t_spec->start_m, t_spec->start_s,
|
snprintf(spec_str, sizeof(spec_str) - 1, "%02d:%02d:%02d-%02d:%02d:%02d", t_spec->start_h, t_spec->start_m, t_spec->start_s,
|
||||||
t_spec->stop_h, t_spec->stop_m, t_spec->stop_s);
|
t_spec->stop_h, t_spec->stop_m, t_spec->stop_s);
|
||||||
if (strlen(spec_str) + strlen(ret) > retlen - 1) {
|
if ((int) (strlen(spec_str) + strlen(ret)) > retlen - 1) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
if (strlen(ret) > 0) {
|
if (strlen(ret) > 0) {
|
||||||
|
Reference in New Issue
Block a user