diff -r 230a502b75ec -r 95cf33f8021f thermferm/mqtt.c --- a/thermferm/mqtt.c Sun Apr 28 19:59:43 2019 +0200 +++ b/thermferm/mqtt.c Thu May 09 16:40:17 2019 +0200 @@ -22,7 +22,6 @@ #include "thermferm.h" #include "rdconfig.h" -#include "logger.h" #include "devices.h" #include "xutil.h" #include "mqtt.h" @@ -153,9 +152,8 @@ void my_log_callback(struct mosquitto *my_mosq, void *obj, int level, const char *str) { -// syslog(LOG_NOTICE, "MQTT: %s", str); - if (debug) - fprintf(stdout, "MQTT: %s\n", str); +// if (debug) +// fprintf(stdout, "MQTT: %s\n", str); } @@ -238,7 +236,6 @@ unit->mqtt_flag |= MQTT_FLAG_DATA; /* Initialize log if the unit is turned on */ if ((unit->mode == UNITMODE_OFF) && (i != UNITMODE_OFF)) { - initlog(unit->product_code, unit->product_name); unit->mqtt_flag |= MQTT_FLAG_BIRTH; } else if ((unit->mode != UNITMODE_OFF) && (i == UNITMODE_OFF)) { unit->mqtt_flag |= MQTT_FLAG_DEATH; @@ -442,7 +439,6 @@ cmd = NULL; } } else if (json_object_object_get_ex(profile, "uuid", &profile1)) { -// syslog(LOG_NOTICE, "profile new profile"); if ((unit->prof_state == PROFILE_OFF) || (unit->prof_state == PROFILE_DONE) || (unit->prof_state == PROFILE_ABORT)) { if (unit->profile_uuid) free(unit->profile_uuid); @@ -458,8 +454,6 @@ } unit->profile_steps = NULL; unit->profile_duration = unit->profile_totalsteps = 0; -// syslog(LOG_NOTICE, "profile new profile: old cleared"); - unit->profile_uuid = xstrcpy((char *)json_object_get_string(profile1)); if (json_object_object_get_ex(profile, "name", &val)) { unit->profile_name = xstrcpy((char *)json_object_get_string(val));