From documentation:
The accept() method will return when a connection from a client is available. In a scalar context the returned value will be a reference to a object of the HTTP::Daemon::ClientConn::SSL class which is another IO::Socket::SSL subclass.So if connection isn't SSL accept returns udef as HTTP::Daemon::ClientConn::SSL object wasn't created and your loop stops.
Update: this works:
while () { my $c = $d->accept or next; while ( my $r = $c->get_request ) { $c->send_file_response('./index.html'); } $c->close; undef($c); }
In reply to Re: HTTP::Daemon::SSL based server dieing when http is requested
by zwon
in thread HTTP::Daemon::SSL based server dieing when http is requested
by bcarroll
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |