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 - 2009, 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.1051 2009/11/24 15:21:51 stewa Exp $"; + constant cvs_version="$Id: roxen.pike,v 1.1052 2009/11/26 17:25:06 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:4395:       string store( mapping args, int|void timeout )    //! Store a mapping (of purely encode_value:able data) in the    //! argument cache. The string returned is your key to retrieve the    //! data later.    //!    //! @param timeout    //! Timeout for the entry in seconds from now. If @expr{UNDEFINED@},    //! the entry will not expire.    { -  if (!zero_type(timeout)) timeout += time(); +  if (!zero_type(timeout)) timeout += time(1);    string encoded_args = encode_value_canonic( args );    string id = Gmp.mpz(Crypto.SHA1.hash(encoded_args), 256)->digits(36);    if( cache[ id ] ) {    if (!no_expiry[id]) {    // The cache id may have a timeout.    if (zero_type(timeout)) {    // No timeout now, but there may have been one earlier.    QUERY("UPDATE LOW_PRIORITY "+name+"2 "    " SET timeout = NULL "    " WHERE id = %s "