Diff for /loncom/loncron between versions 1.90 and 1.92

version 1.90, 2011/06/03 20:45:10 version 1.92, 2011/10/28 18:38:00
Line 652  sub check_delayed_msg { Line 652  sub check_delayed_msg {
 # pong to all servers that have delayed messages  # pong to all servers that have delayed messages
 # this will trigger a reverse connection, which should flush the buffers  # this will trigger a reverse connection, which should flush the buffers
     foreach my $tryserver (keys %servers) {      foreach my $tryserver (keys %servers) {
  my $answer=&Apache::lonnet::reply("pong",$tryserver);          my $answer;
  &log($fh,"Pong to $tryserver: $answer<br />");          eval {
               local $SIG{ ALRM } = sub { die "TIMEOUT" };
               alarm(20);
               $answer = &Apache::lonnet::reply("pong",$tryserver);
               alarm(0);
           };
           if ($@ && $@ =~ m/TIMEOUT/) {
               print "time out while contacting: $tryserver for pong\n";
           } else {
               &log($fh,"Pong to $tryserver: $answer<br />");
           }
     }      }
 }  }
   

Removed from v.1.90  
changed lines
  Added in v.1.92


FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>