Skip to content

Commit

Permalink
oops: r->user = NULL needs to be in session_kill not session_clear
Browse files Browse the repository at this point in the history
Signed-off-by: Hans Zandbelt <[email protected]>
  • Loading branch information
zandbelt committed Jan 26, 2022
1 parent d7d80ed commit 23e4963
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/session.c
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,6 @@ static void oidc_session_uuid_new(request_rec *r, oidc_session_t *z) {
* clear contents of a session
*/
static void oidc_session_clear(request_rec *r, oidc_session_t *z) {
r->user = NULL;
z->uuid[0] = '\0';
z->remote_user = NULL;
// NB: don't clear sid
Expand Down Expand Up @@ -382,6 +381,7 @@ apr_byte_t oidc_session_free(request_rec *r, oidc_session_t *z) {
* terminate a session
*/
apr_byte_t oidc_session_kill(request_rec *r, oidc_session_t *z) {
r->user = NULL;
if (z->state) {
json_decref(z->state);
z->state = NULL;
Expand Down

0 comments on commit 23e4963

Please sign in to comment.