Roxen.git / server / base_server / roxen.pike

version» Context lines:

Roxen.git/server/base_server/roxen.pike:1:   // This file is part of Roxen WebServer.   // Copyright © 1996 - 2004, Roxen IS.   //   // The Roxen WebServer main program.   //   // Per Hedbor, Henrik Grubbström, Pontus Hagland, David Hedbor and others.   // ABS and suicide systems contributed freely by Francesco Chemolli    - constant cvs_version="$Id: roxen.pike,v 1.909 2005/11/25 16:29:33 grubba Exp $"; + constant cvs_version="$Id: roxen.pike,v 1.910 2005/11/30 10:48:53 grubba Exp $";      //! @appears roxen   //!   //! The Roxen WebServer main program.      // The argument cache. Used by the image cache.   ArgCache argcache;      // Some headerfiles   #define IN_ROXEN
Roxen.git/server/base_server/roxen.pike:1400:    if (retries) {    remove_call_out(bind);    }    if (port_obj) {    destruct(port_obj);    }    port_obj = 0;    if (open_ports[name]) {    if (open_ports[name][ip]) {    m_delete(open_ports[name][ip], port); -  if(!sizeof(open_ports[name][ip])) +  if(!sizeof(open_ports[name][ip])) { +  // Make sure the entries for IPv4 and IPv6 ANY are left alone. +  if (ip && ip != "::")    m_delete(open_ports[name], ip);    } -  if(!sizeof(open_ports[name])) +  } +  if (sizeof(open_ports[name]) <= 2) { +  // Only ANY left. +  int empty = 1; +  foreach(open_ports[name]; string ip; mapping m) { +  if (sizeof(m)) { +  empty = 0; +  break; +  } +  } +  if (empty)    m_delete(open_ports, name);    } -  +  }    //destruct( ); // Close the port.    }    }       Stdio.File accept()    {    return port_obj->accept();    }       string query_address()