Permalink
Browse files

remove run_loop from Server implementations. Use register_service if …

…you don't want main event loop run
  • Loading branch information...
miyagawa committed Oct 3, 2009
1 parent 055447e commit 19c5e5efa3d609372ef6d2738af12019f88f95bb
Showing with 4 additions and 2 deletions.
  1. +4 −2 lib/Plack/Server/Danga/Socket.pm
@@ -41,7 +41,7 @@ sub new {
$self;
}
-sub run {
+sub register_service {
my ($self, $app) = @_;
my $ssock = IO::Socket::INET->new(
@@ -90,7 +90,9 @@ sub run {
});
}
-sub run_loop {
+sub run {
+ my $self = shift;
+ $self->register_service(@_);
if ($HasAIO) {
Danga::Socket->AddOtherFds(IO::AIO::poll_fileno() => \&IO::AIO::poll_cb);
}

0 comments on commit 19c5e5e

Please sign in to comment.