From e064fe785388e99180b3faf9b719241362708dab Mon Sep 17 00:00:00 2001 From: Dave West Date: Sat, 19 Jan 2008 23:53:29 +0000 Subject: [PATCH] Fix the user purge / delete thing once and for all. When a user is deleted they are purged from the database immediately unless they are currently logged in. This used to rely on the autopurger purging the user at a later date. Now when the user logs out we check to see if they have been marked for deletion and if they have purge them immediately. --- citadel/user_ops.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/citadel/user_ops.c b/citadel/user_ops.c index 6c16a167a..9cb18c870 100644 --- a/citadel/user_ops.c +++ b/citadel/user_ops.c @@ -606,6 +606,10 @@ void logout(struct CitContext *who) /* Do modular stuff... */ PerformSessionHooks(EVT_LOGOUT); + + /* Check to see if the user was deleted whilst logged in and purge them if necessary */ + if (who->user.axlevel == 0) + purge_user(who->user.fullname); /* Free any output buffers */ if (who->output_buffer != NULL) { -- 2.39.2