]> code.citadel.org Git - citadel.git/blobdiff - citadel/server/user_ops.c
Handle system accounts differently in auto purger
[citadel.git] / citadel / server / user_ops.c
index 0603fc79cf5cc87a2c3dfa61f7ece6eba152c0b5..d45e5004469d69739dc7adc5d1805af2988ce2dd 100644 (file)
@@ -566,6 +566,11 @@ int CtdlLoginExistingUser(const char *trythisname) {
                }
        }
 
+       // User 0 is a system account and must not be used by a real user
+       if (&CC->user.usernum <= 0) {
+               return login_not_found;
+       }
+
        // Did we find something?
        if (found_user == 0) {
                if (((CC->nologin)) && (CC->user.axlevel < AxAideU)) {