I read in lighttpd 1.4.19 source codes, now I got stuck at the function fcgi_spawn_connection,
if (-1 == connect(fcgi_fd, fcgi_addr, servlen)) {
...
bind(fcgi_fd, fcgi_addr, servlen)
...
listen(fcgi_fd, 1024)
}
The question is, why does mod_fastcgi create a listening socket, what's it use for? Isn't that mod_fastcgi works as client connect to fastcgi processes(etc, php-cgi)? - the php-cgi processes will listen.
Thanks.