Hi,

I'am writing a frontend to LXD and uses a Unix-Socket for the http-Request:

...
static prefix = "http+unix://%2Fvar%2Flib%2Flxd%2Funix.socket";

ServerInfo getBackendInfo(string name)
{
 ServerInfo ret;
 HTTPClientSettings settings = new HTTPClientSettings;
 settings.defaultKeepAliveTimeout = 0.seconds;
 auto url2 = URL(prefix ~ "/1.0/containers/"~  name ~ "/state");
 workon = &ret;
 requestHTTP(url2,
             (scope req) { req.method=HTTPMethod.GET; },
			 &this.getContainerIp,
			 settings);
 return ret;
}

Calling getBackendInfo with different names leeds in Failed to bind socket. (Address already in use) from time to time.

Is there any possibility to free the socket after the call?

Regards

Markus