Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
improve Hypnotoad to report problems that have occured during the cre…
…ation of listen sockets
  • Loading branch information
kraih committed Nov 27, 2015
1 parent 2531199 commit 350c563
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 2 deletions.
2 changes: 2 additions & 0 deletions Changes
@@ -1,5 +1,7 @@

6.34 2015-11-27
- Improved Hypnotoad to report problems that have occured during the creation
of listen sockets.
- Fixed bug in Mojo::DOM where the wrap method would attempt to wrap an
HTML/XML fragment around the content of root nodes.
- Fixed bug in Mojo::DOM where the wrap_content method would attempt to wrap
Expand Down
2 changes: 1 addition & 1 deletion lib/Mojo/Server/Daemon.pm
Expand Up @@ -47,7 +47,7 @@ sub start {
}

# Start listening
else { $self->_listen($_) for @{$self->listen} }
elsif (!@{$self->acceptors}) { $self->_listen($_) for @{$self->listen} }

return $self;
}
Expand Down
1 change: 1 addition & 0 deletions lib/Mojo/Server/Hypnotoad.pm
Expand Up @@ -68,6 +68,7 @@ sub run {
$self->_hot_deploy unless $ENV{HYPNOTOAD_PID};
# Daemonize as early as possible (but not for restarts)
$prefork->start;
$prefork->daemonize if !$ENV{HYPNOTOAD_FOREGROUND} && $ENV{HYPNOTOAD_REV} < 3;
# Start accepting connections
Expand Down
2 changes: 1 addition & 1 deletion t/mojo/daemon.t
Expand Up @@ -267,7 +267,7 @@ $daemon = Mojo::Server::Daemon->new(
silent => 1
);
is scalar @{$daemon->acceptors}, 0, 'no active acceptors';
is scalar @{$daemon->start->acceptors}, 1, 'one active acceptor';
is scalar @{$daemon->start->start->acceptors}, 1, 'one active acceptor';
is $daemon->ioloop->max_connections, 23, 'right value';
$id = $daemon->acceptors->[0];
ok !!Mojo::IOLoop->acceptor($id), 'acceptor has been added';
Expand Down

0 comments on commit 350c563

Please sign in to comment.