diff --git a/src/remote/remote_driver.c b/src/remote/remote_driver.c index c078cb54e6..65fcc5b9fa 100644 --- a/src/remote/remote_driver.c +++ b/src/remote/remote_driver.c @@ -3738,7 +3738,8 @@ static int remoteAuthFillFromConfig(virConnectPtr conn, break; } - if (virAuthConfigLookup(state->config, + if (credname && + virAuthConfigLookup(state->config, "libvirt", VIR_URI_SERVER(conn->uri), credname,