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.400 2000/12/05 22:27:18 nilsson Exp $"; + constant cvs_version = "$Id: configuration.pike,v 1.401 2000/12/10 02:01:42 per 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:220:    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); +  registered_urls = ({});   }      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";       string ext=myext || Roxen.extension(file);   
Roxen.git/server/base_server/configuration.pike:953:    else if (objectp(m->file))    if (catch {    Stat a=m->file->stat();    res += sprintf("%d bytes ", a[1]-m->file->tell());    })    res += "? bytes ";       if (m->data) res += "(static)";    else if (m->file) res += "(open file)";    -  if (stringp(m->extra_heads["http-content-type"]) || +  if (stringp(m->extra_heads["content-type"]) ||    stringp(m->type)) { -  res += sprintf(" of %s", m->type); +  res += sprintf(" of %s", m->type||m->extra_heads["content-type"]);    }       res+="<br />";       return res;   }      mapping|int(-1..0) low_get_file(RequestID id, int|void no_magic)   //! The function that actually tries to find the data requested. All   //! modules except last and filter type modules are mapped, in order,
Roxen.git/server/base_server/configuration.pike:1008: Inside #if undefined(NO_INTERNAL_HACK) and #if defined(OLD_RXML_COMPAT)
   (file[0] == '/') &&    sscanf(file, "%*s/internal-%s-%[^/]", type, loc) == 3   #else    sscanf(file, "/internal-%s-%[^/]", type, loc) == 2   #endif    ) {    switch(type) {    case "roxen":    TRACE_LEAVE("Magic internal roxen image");    if(loc=="unit") -  return (["data":"GIF89a\1\0\1\0\200ÿ\0ÀÀÀ\0\0\0!ù\4\1\0\0\0\0,\0\0\0\0\1\0\1\0\0\1\1""2\0;", +  return (["data":"GIF89a\1\0\1\0\200\0ÀÀÀ\0\0\0!\4\1\0\0\0\0,\0\0\0\0\1\0\1\0\0\1\1""2\0;",    "type":"image/gif" ]);    return internal_roxen_image(loc, id);       case "gopher":    TRACE_LEAVE("Magic internal gopher image");    return internal_gopher_image(loc);    }    }   #endif