fix bool leakage

This commit is contained in:
SH 2020-11-26 08:33:58 +01:00
parent 3f74b3a8aa
commit 2a43004b71
2 changed files with 2 additions and 2 deletions

View File

@ -145,7 +145,7 @@ struct st_kisstnc {
}; };
struct st_mqtt { struct st_mqtt {
bool active; int active;
char id[64]; char id[64];
char host[64]; char host[64];
int port; int port;

View File

@ -23,7 +23,7 @@ void MQTT::init(const char* ip, uint16_t port, const char* id, const char *usern
this->prefix = prefix; this->prefix = prefix;
char buffer[20]; char buffer[20];
snprintf(buffer, 20, "%s%d", id, random(0, 1000)); snprintf(buffer, 20, "%s%6ld", id, random(0, 1000));
this->id = buffer; this->id = buffer;
Serial.println("[MQTT] pubsub client"); Serial.println("[MQTT] pubsub client");