mirror of
https://github.com/apache/httpd.git
synced 2025-08-03 16:33:59 +00:00
mod_session: Reset the max-age on session save. PR 47476.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1531683 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
3
CHANGES
3
CHANGES
@ -1,6 +1,9 @@
|
|||||||
-*- coding: utf-8 -*-
|
-*- coding: utf-8 -*-
|
||||||
Changes with Apache 2.5.0
|
Changes with Apache 2.5.0
|
||||||
|
|
||||||
|
*) mod_session: Reset the max-age on session save. PR 47476. [Alexey
|
||||||
|
Varlamov <alexey.v.varlamov gmail com>]
|
||||||
|
|
||||||
*) mod_session: After parsing the value of the header specified by the
|
*) mod_session: After parsing the value of the header specified by the
|
||||||
SessionHeader directive, remove the value from the response. PR 55279.
|
SessionHeader directive, remove the value from the response. PR 55279.
|
||||||
[Graham Leggett]
|
[Graham Leggett]
|
||||||
|
@ -144,9 +144,11 @@ static apr_status_t ap_session_load(request_rec * r, session_rec ** z)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* make sure the expiry is set, if present */
|
/* make sure the expiry and maxage are set, if present */
|
||||||
if (!zz->expiry && dconf->maxage) {
|
if (dconf->maxage) {
|
||||||
|
if (!zz->expiry) {
|
||||||
zz->expiry = now + dconf->maxage * APR_USEC_PER_SEC;
|
zz->expiry = now + dconf->maxage * APR_USEC_PER_SEC;
|
||||||
|
}
|
||||||
zz->maxage = dconf->maxage;
|
zz->maxage = dconf->maxage;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -194,6 +196,11 @@ static apr_status_t ap_session_save(request_rec * r, session_rec * z)
|
|||||||
z->maxage = dconf->maxage;
|
z->maxage = dconf->maxage;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* reset the expiry before saving if present */
|
||||||
|
if (z->dirty && z->maxage) {
|
||||||
|
z->expiry = now + z->maxage * APR_USEC_PER_SEC;
|
||||||
|
}
|
||||||
|
|
||||||
/* encode the session */
|
/* encode the session */
|
||||||
rv = ap_run_session_encode(r, z);
|
rv = ap_run_session_encode(r, z);
|
||||||
if (OK != rv) {
|
if (OK != rv) {
|
||||||
|
Reference in New Issue
Block a user