Roxen.git / server / base_server / configuration.pike

version» Context lines:

Roxen.git/server/base_server/configuration.pike:1:   // This file is part of Roxen WebServer.   // Copyright © 1996 - 2001, Roxen IS.   //      // @appears Configuration   //! A site's main configuration    - constant cvs_version = "$Id: configuration.pike,v 1.575 2004/05/14 18:09:05 grubba Exp $"; + constant cvs_version = "$Id: configuration.pike,v 1.576 2004/05/18 12:46:53 anders Exp $";   #include <module.h>   #include <module_constants.h>   #include <roxen.h>   #include <request_trace.h>   #include <timers.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:2397:       return ({ 0, file });    }       if( file->data )    {    file->file = StringFile(file->data);    m_delete(file, "data");    }    id->not_query = oq; -  return ({ file->file, file }); +  return ({ file->file || StringFile(""), file });   }         mapping(string:array(mixed)) find_dir_stat(string file, RequestID id)   {    string loc;    mapping(string:array(mixed)) dir = ([]);    mixed d, tmp;      
Roxen.git/server/base_server/configuration.pike:2677:   //! the id->misc->internal_get flag being non-zero.   {    string res;    RequestID fake_id = make_fake_id (s, id);    mapping m;       fake_id->misc->internal_get = !not_internal;    fake_id->method = "GET";       array a = open_file( fake_id->not_query, "r", fake_id, !not_internal ); -  if(a && a[0]) { +     m = a[1]; -  +  +  if (result_mapping) +  foreach(indices(m), string i) +  result_mapping[i] = m[i]; +  +  if(a[0]) {    m->file = a[0];    }    else {    destruct (fake_id);    return 0;    }       CACHE( fake_id->misc->cacheable );    destruct (fake_id);    -  if (result_mapping) -  foreach(indices(m), string i) -  result_mapping[i] = m[i]; -  +     // Allow 2* and 3* error codes, not only a few specific ones.    if (!(< 0,2,3 >)[m->error/100]) return 0;       if(stat_only) return 1;       if(m->data)    res = m->data;    else    res="";    m->data = 0;