From aa389d5c40adf87d2f577554b959c66465f5b255 Mon Sep 17 00:00:00 2001 From: Tobias Reisinger Date: Thu, 2 Jul 2020 14:58:30 +0200 Subject: [PATCH] hotfix: bad mqtt connection address --- CMakeLists.txt | 2 +- src/connections.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 48f8dd6..a85fc70 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,6 +1,6 @@ cmake_minimum_required (VERSION 3.7) project(controller - VERSION 0.2.3 + VERSION 0.2.4 LANGUAGES C) add_executable(controller src/main.c) diff --git a/src/connections.c b/src/connections.c index 3be866f..2f2b2f2 100644 --- a/src/connections.c +++ b/src/connections.c @@ -29,7 +29,7 @@ struct mg_connection* connection_mqtt_connect(struct mg_mgr *mgr) { char address[100]; - sprintf(address, "tcp://localhost:%u", global_config.mqtt_port); + sprintf(address, "tcp://127.0.0.1:%u", global_config.mqtt_port); struct mg_connection *c = mg_connect(mgr, address, handler_mqtt); return c; }