void pobox_check(int id, struct user *u)
{
+ struct filesys *fs;
+
switch (u->potype)
{
case 'P':
}
}
break;
+
case 'S':
if (hash_lookup(string_dups, u->pobox_id))
{
}
}
break;
+
+ case 'I':
+ fs = hash_lookup(filesys, u->pobox_id);
+ if (!fs)
+ {
+ printf("User %s(%s) has P.O.Box on non-existant filesystem %d\n",
+ u->login, u->fullname, u->pobox_id);
+ if (single_fix("Delete", 0))
+ {
+ remove_pobox(u->users_id);
+ u->potype = 'N';
+ }
+ }
+ else if (fs->type != 'I')
+ {
+ printf("User %s(%s) has IMAP P.O.Box on non-IMAP filesystem %s\n",
+ u->login, u->fullname, fs->name);
+ if (single_fix("Delete", 0))
+ {
+ remove_pobox(u->users_id);
+ u->potype = 'N';
+ }
+ }
+ break;
+
default:
;
}
}
}
- if (f->type == 'N')
+ if (f->type == 'N' || f->type == 'I')
{
if (!hash_lookup(nfsphys, f->phys_id))
{