Test: Fix incorrect address, and give better http-api failure msg

This commit is contained in:
Roger A. Light 2026-05-18 18:46:15 +01:00
parent 45a1c97724
commit db988a6e4a
No known key found for this signature in database
GPG key ID: 779B22DFB3E717B7
2 changed files with 3 additions and 3 deletions

View file

@ -497,7 +497,7 @@ int http_api__start(struct mosquitto__listener *listener)
int rc = getaddrinfo(bind_address, service, &hints, &ainfo);
if(rc){
log__printf(NULL, MOSQ_LOG_ERR, "Unable to start http api listener.");
log__printf(NULL, MOSQ_LOG_ERR, "Unable to start http api listener (%s).", strerror(errno));
mosquitto_FREE(x509_cert);
mosquitto_FREE(x509_key);
return MOSQ_ERR_ERRNO;

View file

@ -20,9 +20,9 @@ broker_config = BrokerConfig(
ListenerConfig(port=mqtt_port),
ListenerConfig(
port=http_port,
address="127.0.01",
address="127.0.0.1",
protocol="http_api",
http_dir=".",
http_dir=Path("."),
)
],
allow_anonymous=True