Maidag: avoid using auth_by_uid when delivering message.
When delivering message, the library may need to know the email address of the user on behalf of whom maidag is called. In particular, that happens when using the vacation extension. In that case the library would construct the email by concatenating user name, obtained as a result of mu_get_auth_by_uid, and current domain name. Avoid this by remembering email address the message is being delivered to. * libmailutils/base/usremail.c (mu_set_user_email): NULL argument clears email. (mu_get_user_email): Use EUID instead of UID. * maidag/deliver.c (do_delivery): Set user email prior to delivery. * maidag/maidag.c (default_domain): New variable. (maidag_cfg_param): New setting "domain". * maidag/maidag.h (default_domain): New extern.
Showing
4 changed files
with
26 additions
and
7 deletions
-
Please register or sign in to post a comment