(file) Return to cimserver.cpp CVS log (file) (dir) Up to [Pegasus] / pegasus / src / Server

Diff for /pegasus/src/Server/cimserver.cpp between version 1.28 and 1.29

version 1.28, 2001/06/23 21:42:58 version 1.29, 2001/06/25 17:51:59
Line 347 
Line 347 
     // try loop to bind the address, and run the server     // try loop to bind the address, and run the server
     try     try
     {     {
           slp_client *discovery = new slp_client() ;;
         String serviceURL;         String serviceURL;
         serviceURL.assign("service:cim.pegasus://");         serviceURL.assign("service:cim.pegasus://");
         char *host_name = slp_get_host_name();          String host_name = slp_get_host_name();
         serviceURL += host_name;         serviceURL += host_name;
         serviceURL += ":";         serviceURL += ":";
         serviceURL += address;         serviceURL += address;
         char *url = serviceURL.allocateCString();         char *url = serviceURL.allocateCString();
         free(host_name);          //      free(host_name);
  
         Selector selector;         Selector selector;
         CIMServer server(&selector, pegasusHome);         CIMServer server(&selector, pegasusHome);
Line 363 
Line 364 
         server.bind(address);         server.bind(address);
         delete [] address;         delete [] address;
  
         slp_client *discovery = NULL;  
         if(useSLP)  
           discovery = new slp_client();  
  
         time_t last = 0;         time_t last = 0;
         while( 1 )         while( 1 )
         {         {
           if(useSLP  )           if(useSLP  )
           {           {
             int success, failure;  
   
             if(  (time(NULL) - last ) > 60 )             if(  (time(NULL) - last ) > 60 )
             {             {
               if( discovery != NULL && url != NULL )               if( discovery != NULL && url != NULL )
Line 381 
Line 378 
                                        "(namespace=root/cimv20)",                                        "(namespace=root/cimv20)",
                                        "service:cim.pegasus",                                        "service:cim.pegasus",
                                        "DEFAULT",                                        "DEFAULT",
                                        3600) ;                                         70) ;
               time(&last);               time(&last);
             }             }
   
               discovery->service_listener();
           }           }
           server.runForever();           server.runForever();
         }         }


Legend:
Removed from v.1.28  
changed lines
  Added in v.1.29

No CVS admin address has been configured
Powered by
ViewCVS 0.9.2