[Dovecot] 'Doveadm user' could use better error codes
dovecot
dovecot at vosslamber.nl
Tue Dec 28 16:52:50 EET 2010
On 28-12-10 15:37, Thomas Leuxner wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Am 28.12.2010 um 15:34 schrieb dovecot:
>> $ doveadm user dovecot
>> userdb: dovecot
>> system_groups_user: dovecot
>> uid : 114
>> gid : 114
>> home : /usr/local/lib/dovecot
>> $ echo $?
>> 0
> Nothing new, used a similar example in my first mail. Now try with a non-existent user and tell me what it should come up with? (*drum roll*)
>
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG/MacGPG2 v2.0.16 (Darwin)
>
> iEYEARECAAYFAk0Z9ksACgkQ+meF/S97aXhntwCgjjmO+gGIsoub/V09KvEkhGmu
> luoAnA3K8NIk9MGcMkNcdP1iCaTMOnos
> =ikRL
> -----END PGP SIGNATURE-----
>
$ doveadm user abcd
userdb lookup: user abcd doesn't exist
$ echo $?
0
Based on the output of '0', the "Selected command was executed successful."
And it is informing you that a user with the name 'abcd' doent exist....
But, indeed, it would be better to return an error in this case
More information about the dovecot
mailing list