diff --git a/lib/net_mosq.c b/lib/net_mosq.c index ed783cad..3d472597 100644 --- a/lib/net_mosq.c +++ b/lib/net_mosq.c @@ -665,7 +665,7 @@ int net__socket_connect(struct mosquitto *mosq, const char *host, uint16_t port, mosq->sock = sock; -#ifdef WITH_SOCKS +#if defined(WITH_SOCKS) && !defined(WITH_BROKER) if(!mosq->socks5_host) #endif {