suppress warnings
This commit is contained in:
@@ -178,7 +178,9 @@ char* MQTTFormat_toClientString(char* strbuf, int32_t strbuflen, uint8_t* buf, i
|
|||||||
strindex = snprintf(strbuf, strbuflen, "%s", MQTTPacket_names[header.bits.type]);
|
strindex = snprintf(strbuf, strbuflen, "%s", MQTTPacket_names[header.bits.type]);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
(void) strindex;
|
||||||
|
|
||||||
return strbuf;
|
return strbuf;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -260,6 +262,7 @@ char* MQTTFormat_toServerString(char* strbuf, int32_t strbuflen, uint8_t* buf, i
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
(void) strindex;
|
||||||
strbuf[strbuflen] = '\0';
|
strbuf[strbuflen] = '\0';
|
||||||
return strbuf;
|
return strbuf;
|
||||||
}
|
}
|
||||||
|
|||||||
12
mqtt.c
12
mqtt.c
@@ -56,11 +56,11 @@ void mqtt_pub(Client* mqtt_client, char * mqtt_topic, char * mqtt_msg, int mqtt_
|
|||||||
{
|
{
|
||||||
printf(" - ERROR\r\n");
|
printf(" - ERROR\r\n");
|
||||||
//Reboot device after 20 continuous errors (~ 20sec)
|
//Reboot device after 20 continuous errors (~ 20sec)
|
||||||
while(1);
|
//while(1);
|
||||||
//if(mqtt_err_cnt++ > 20)
|
if(mqtt_err_cnt++ > 20)
|
||||||
//{
|
{
|
||||||
// printf("Connection with MQTT Broker was lost!!\r\nReboot the board..\r\n");
|
printf("Connection with MQTT Broker was lost!!\r\nReboot the board..\r\n");
|
||||||
// while(1);
|
while(1);
|
||||||
//}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user