Branch: Tag:

1999-10-06

1999-10-06 23:07:36 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Fixed typo.
Added support for a few more protocols (most of them probably don't work).

Rev: server/base_server/roxen.pike:1.329

1:   /* -  * $Id: roxen.pike,v 1.328 1999/10/04 18:53:21 marcus Exp $ +  * $Id: roxen.pike,v 1.329 1999/10/06 23:07:36 grubba Exp $    *    * The Roxen Challenger main program.    *
7:    */      // ABS and suicide systems contributed freely by Francesco Chemolli - constant cvs_version="$Id: roxen.pike,v 1.328 1999/10/04 18:53:21 marcus Exp $"; + constant cvs_version="$Id: roxen.pike,v 1.329 1999/10/06 23:07:36 grubba Exp $";      object backend_thread;   object argcache;
684: Inside #if 1
   constant default_port = 80;   }    + class HTTPS + { +  inherit Protocol; +  constant supports_ipless = 0; +  constant name = "https"; +  constant requesthandlerfile = "protocols/https.pike"; +  constant default_port = 443; + } +  + class FTP + { +  inherit Protocol; +  constant supports_ipless = 0; +  constant name = "ftp"; +  constant requesthandlerfile = "protocols/ftp.pike"; +  constant default_port = 21; + } +  + class GOPHER + { +  inherit Protocol; +  constant supports_ipless = 0; +  constant name = "gopher"; +  constant requesthandlerfile = "protocols/gopher.pike"; +  constant default_port = 70; + } +  + class TETRIS + { +  inherit Protocol; +  constant supports_ipless = 0; +  constant name = "tetris"; +  constant requesthandlerfile = "protocols/tetris.pike"; +  constant default_port = 2050; + } +    mapping protocols = ([    "http":HTTP, -  +  "https":HTTPS, +  "ftp":FTP, +  "gopher":GOPHER, +  "tetris":TETRIS,   ]);      mapping(string:mapping) open_ports = ([ ]);
737: Inside #if 1
      string required_host;    -  url = replace( url, "/ANY", "*" ); -  url = replace( url, "/any", "*" ); +  url = replace( url, "/ANY", "/*" ); +  url = replace( url, "/any", "/*" );       sscanf( url, "%[^:]://%[^/]%s", protocol, host, path );    sscanf( host, "%[^:]:%d", host, port );