Roxen.git / server / modules / filesystems / filesystem.pike

version» Context lines:

Roxen.git/server/modules/filesystems/filesystem.pike:1:   // This is a ChiliMoon module. Copyright © 1996 - 2001, Roxen IS.      // This is a virtual "file-system".   // It will be located somewhere in the name-space of the server.   // Also inherited by some of the other filesystems.      inherit "module";   inherit "socket";    - constant cvs_version = "$Id: filesystem.pike,v 1.122 2004/05/22 11:05:45 _cvs_stephen Exp $"; + constant cvs_version = "$Id: filesystem.pike,v 1.123 2004/05/22 11:08:54 _cvs_stephen Exp $";   constant thread_safe = 1;      #include <module.h>   #include <stat.h>   #include <request_trace.h>   #include <roxen.h>      // NGSERVER: Make an API where a module can send back an error token which is   // then substituted with the apropriate message for the protocol and locale.   // This would enable us to theme other error pages than the now special case 404.
Roxen.git/server/modules/filesystems/filesystem.pike:751:    object o;    int size;    string tmp;    string oldf = f;    object privs;    int code;       FILESYSTEM_WERR("Request for \""+f+"\"" +    (id->misc->internal_get ? " (internal)" : ""));    +  string cmethod; +  switch(cmethod=id->method) +  { case "PUT":case "DELETE":case "MKDIR": // Hack to support processing +  if(!query("put")) // these using RXML +  cmethod="POST"; +  } +     /* only used for the quota system, thus rather unessesary to do for    each request....    */   #define URI combine_path(mountpoint + "/" + oldf, ".")       string norm_f;       catch {    /* NOTE: NORMALIZE_PATH() may throw errors. */    f = norm_f = NORMALIZE_PATH(f = decode_path(path + f));
Roxen.git/server/modules/filesystems/filesystem.pike:798:    // NOTE: Sets id->misc->stat.    size = _file_size( f, id );       FILESYSTEM_WERR(sprintf("_file_size(%O, %O) ==> %d\n", f, id, size));       /*    * FIXME: Should probably move path-info extraction here.    * /grubba 1998-08-26    */    -  switch(id->method) +  switch(cmethod)    {    case "GET":    case "HEAD":    case "POST":       switch(-size)    {    case 1:    case 3:    case 4: