fix ipaddr handling for MQTT topic