count requests with current client
authorDobrica Pavlinusic <dpavlin@rot13.org>
Sun, 7 Mar 2010 19:22:33 +0000 (19:22 +0000)
committerDobrica Pavlinusic <dpavlin@rot13.org>
Sun, 7 Mar 2010 19:22:33 +0000 (19:22 +0000)
git-svn-id: https://perl-cwmp.googlecode.com/svn/trunk@264 836a5e1a-633d-0410-964b-294494ad4392

lib/CWMP/Server.pm

index f90b115..eaf6c06 100644 (file)
@@ -90,10 +90,13 @@ sub run {
        while (1) {
                my $client = $server->accept() || next; # ALARM trickle us
 
+               my $count = 0;
+
                my $session = CWMP::Session->new( $self->session ) || confess "can't create sessision";
 
                while ( $self->sock_session( $client, $session ) ) {
-                       warn "# another one\n";
+                       $count++;
+                       warn "# finished request $count, waiting for next one\n";
                }
 
                warn "# connection to ", $client->peerhost, " closed\n";