diff --git a/gestion/ldap_crans.py b/gestion/ldap_crans.py index eff20c30..be12af74 100755 --- a/gestion/ldap_crans.py +++ b/gestion/ldap_crans.py @@ -1902,6 +1902,9 @@ class club(base_proprietaire): home = '/home/' + login.replace('-','/',1) if os.path.exists(home): raise ValueError(u'Création du compte impossible : home existant',1) + + if os.path.exists("/var/mail/"+login): + raise ValueError(u'Création du compte impossible : /var/mail/%s existant'%login,1) # Lock du mail self.lock('mail',login)