Skip to content

Commit

Permalink
oops: fix oidc_parse_expires_in broken in previous commit
Browse files Browse the repository at this point in the history
Signed-off-by: Hans Zandbelt <hans.zandbelt@openidc.com>
  • Loading branch information
zandbelt committed Nov 7, 2023
1 parent 7de72d4 commit 0f2389b
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/mod_auth_openidc.c
Original file line number Diff line number Diff line change
Expand Up @@ -2144,11 +2144,10 @@ static apr_byte_t oidc_save_in_session(request_rec *r, oidc_cfg *c,
* parse the expiry for the access token
*/
static int oidc_parse_expires_in(request_rec *r, const char *expires_in) {
if (expires_in != NULL)
return -1;
int number = _oidc_str_to_int(expires_in);
if (number <= 0)
oidc_warn(r, "could not convert \"expires_in\" value (%s) to a number",
oidc_warn(r,
"could not parse \"expires_in\" value (%s) into a positive integer",
expires_in);
return number;
}
Expand Down

0 comments on commit 0f2389b

Please sign in to comment.