[LON-CAPA-cvs] cvs: loncom /lonnet/perl lonnet.pm

www lon-capa-cvs@mail.lon-capa.org
Wed, 26 Jun 2002 19:46:20 -0000


www		Wed Jun 26 15:46:20 2002 EDT

  Modified files:              
    /loncom/lonnet/perl	lonnet.pm 
  Log:
  Bug 476
  Reads domain descriptions into %Apache::lonnet::domaindescription
  
  
Index: loncom/lonnet/perl/lonnet.pm
diff -u loncom/lonnet/perl/lonnet.pm:1.244 loncom/lonnet/perl/lonnet.pm:1.245
--- loncom/lonnet/perl/lonnet.pm:1.244	Mon Jun 24 16:25:44 2002
+++ loncom/lonnet/perl/lonnet.pm	Wed Jun 26 15:46:19 2002
@@ -1,7 +1,7 @@
 # The LearningOnline Network
 # TCP networking package
 #
-# $Id: lonnet.pm,v 1.244 2002/06/24 20:25:44 matthew Exp $
+# $Id: lonnet.pm,v 1.245 2002/06/26 19:46:19 www Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -80,7 +80,7 @@
 qw(%perlvar %hostname %homecache %badServerCache %hostip %spareid %hostdom 
    %libserv %pr %prp %metacache %packagetab 
    %courselogs %accesshash $processmarker $dumpcount 
-   %coursedombuf %coursehombuf %courseresdatacache);
+   %coursedombuf %coursehombuf %courseresdatacache %domaindescription);
 use IO::Socket;
 use GDBM_File;
 use Apache::Constants qw(:common :http);
@@ -2943,10 +2943,13 @@
 
     while (my $configline=<$config>) {
        chomp($configline);
-       my ($id,$domain,$role,$name,$ip)=split(/:/,$configline);
+       my ($id,$domain,$role,$name,$ip,$domdescr)=split(/:/,$configline);
        $hostname{$id}=$name;
        $hostdom{$id}=$domain;
        $hostip{$id}=$ip;
+       if ($domdescr) {
+	   $domaindescription{$domain}=$domdescr;
+       }
        if ($role eq 'library') { $libserv{$id}=$name; }
     }
 }