Deleted the jwt_token when the user logs out.
This commit is contained in:
parent
2771ab1516
commit
aa9e42933b
|
@ -145,9 +145,13 @@ int main() {
|
||||||
RESTORE_SOCKFD(logout_ret == OPERATION_CONNECTION_CLOSED,
|
RESTORE_SOCKFD(logout_ret == OPERATION_CONNECTION_CLOSED,
|
||||||
sockfd, server_ip);
|
sockfd, server_ip);
|
||||||
|
|
||||||
// delete the cookie if the operation was successful
|
/*
|
||||||
|
* Delete the cookie and the jwt_token if the operation was successful.
|
||||||
|
*
|
||||||
|
*/
|
||||||
if (logout_ret == OPERATION_SUCCESSFUL) {
|
if (logout_ret == OPERATION_SUCCESSFUL) {
|
||||||
FREE(cookie);
|
FREE(cookie);
|
||||||
|
FREE(jwt_token);
|
||||||
}
|
}
|
||||||
|
|
||||||
} else if (strncmp(input_buffer, EXIT, sizeof(EXIT) - 1) == 0) {
|
} else if (strncmp(input_buffer, EXIT, sizeof(EXIT) - 1) == 0) {
|
||||||
|
|
|
@ -661,18 +661,3 @@ logout_end:
|
||||||
return return_status;
|
return return_status;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue