Roxen.git / server / base_server / configuration.pike

version» Context lines:

Roxen.git/server/base_server/configuration.pike:1:   // A vitual server's main configuration   // Copyright © 1996 - 2000, Roxen IS. - constant cvs_version = "$Id: configuration.pike,v 1.385 2000/10/10 14:15:30 jhs Exp $"; + constant cvs_version = "$Id: configuration.pike,v 1.386 2000/10/29 03:40:58 mast Exp $";   #include <module.h>   #include <module_constants.h>   #include <roxen.h>   #include <request_trace.h>         #define CATCH(P,X) do{mixed e;if(e=catch{X;})report_error("While "+P+"\n"+describe_backtrace(e));}while(0)      // --- Locale defines ---   //<locale-token project="roxen_start"> LOC_S </locale-token>
Roxen.git/server/base_server/configuration.pike:200:   private array (function) logger_module_cache, first_module_cache;   private array (function) filter_module_cache;   private array (array (string|function)) location_module_cache;   private mapping (string:array (function)) file_extension_module_cache=([]);   private mapping (string:array (RoxenModule)) provider_module_cache=([]);         // Call stop in all modules.   void stop()   { +  multiset allmods = mkmultiset (indices (otomod));    CATCH("stopping type modules",    types_module && types_module->stop && types_module->stop()); -  +  allmods[types_module] = 0;    CATCH("stopping auth module",    auth_module && auth_module->stop && auth_module->stop()); -  +  allmods[auth_module] = 0;    CATCH("stopping directory module",    dir_module && dir_module->stop && dir_module->stop()); -  +  allmods[dir_module] = 0;    for(int i=0; i<10; i++)    CATCH("stopping priority group", -  (pri[i] && pri[i]->stop && pri[i]->stop())); +  (pri[i] && pri[i]->stop && (allmods -= mkmultiset (pri[i]->stop()))));    CATCH("stopping the logger",    log_function && lambda(mixed m){    destruct(m); -  +  allmods[m] = 0;    }(function_object(log_function))); -  +  foreach (indices (allmods), RoxenModule m) +  CATCH ("stopping unclassified module", +  m && m->stop && m->stop());    foreach( registered_urls, string url )    roxen.unregister_url(url);   }      string type_from_filename( string file, int|void to, string|void myext )   {    array(string)|string tmp;    if(!types_fun)    return to?({ "application/octet-stream", 0 }):"application/octet-stream";