mirror of https://github.com/adamdruppe/arsd.git
all only host to be specified for unix sockets
This commit is contained in:
parent
ea0eb49d64
commit
fa53cb3395
4
cgi.d
4
cgi.d
|
@ -4010,16 +4010,16 @@ void serveFastCgi(alias fun, CustomCgi = Cgi, long maxContentLength = defaultMax
|
|||
}
|
||||
|
||||
auto lp = params.listeningPort;
|
||||
auto host = params.listeningHost;
|
||||
|
||||
FCGX_Request request;
|
||||
if(lp) {
|
||||
if(lp || !host.empty) {
|
||||
// if a listening port was specified on the command line, we want to spawn ourself
|
||||
// (needed for nginx without spawn-fcgi, e.g. on Windows)
|
||||
FCGX_Init();
|
||||
|
||||
int sock;
|
||||
|
||||
auto host = params.listeningHost;
|
||||
if(host.startsWith("unix:")) {
|
||||
sock = FCGX_OpenSocket(toStringz(params.listeningHost["unix:".length .. $]), 12);
|
||||
} else if(host.startsWith("abstract:")) {
|
||||
|
|
Loading…
Reference in New Issue