Show
Ignore:
Timestamp:
06/20/05 17:32:00 (4 years ago)
Author:
zoeloelip
Message:

Reverted the patch for the gc_maxlifetime setting when using

user functions for the session handler. I can't find a way to
access the current value instead of the ini setting.
Using the session api is the preffered session handling way anyway.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • eaccelerator/trunk/session.c

    r106 r107  
    9696} 
    9797 
    98 #ifdef HAVE_PHP_SESSIONS_SUPPORT  /* PHP_SESSION_API >= 20020306 */ 
     98#ifdef HAVE_PHP_SESSIONS_SUPPORT       /* PHP_SESSION_API >= 20020306 */ 
    9999/******************************************************************************/ 
    100100/* Session api functions                                                                                                          */ 
     
    151151        time_t ttl; 
    152152        zval sval; 
     153        char *tmp; 
    153154 
    154155        len = sizeof ("sess_") + strlen (key); 
     
    156157        strcpy (skey, "sess_"); 
    157158        strcat (skey, key); 
    158         ttl = PS(gc_maxlifetime); 
    159         if (ttl < 0) 
    160                 ttl = 1440; 
     159        if (cfg_get_string ("session.gc_maxlifetime", &tmp) == FAILURE) { 
     160                ttl = 1440; 
     161        } else { 
     162                ttl = atoi (tmp); 
     163        } 
    161164        sval.type = IS_STRING; 
    162165        sval.value.str.val = (char *) val; 
     
    331334        strcpy (key, "sess_"); 
    332335        strcat (key, (*arg_key)->value.str.val); 
    333         ttl = PS(gc_maxlifetime); 
     336        ttl = PS (gc_maxlifetime); 
    334337        if (ttl < 0) 
    335338                ttl = 1440; 
     
    377380        RETURN_TRUE; 
    378381} 
    379 #endif                                                 /* ELSE HAVE_PHP_SESSIONS_SUPPORT */ 
     382#endif /* ELSE HAVE_PHP_SESSIONS_SUPPORT */ 
    380383 
    381384ps_module ps_mod_eaccelerator = { 
     
    407410        zval retval; 
    408411        int ret = 1; 
    409 #ifdef HAVE_PHP_SESSIONS_SUPPORT // do it with the session api 
     412#ifdef HAVE_PHP_SESSIONS_SUPPORT       // do it with the session api 
    410413        zval param; 
    411414        zval *params[1];