X-Git-Url: https://code.citadel.org/?p=citadel.git;a=blobdiff_plain;f=citadel%2Fuser_ops.c;h=607f16b3aed96cf3388b5731a306bd6048af23b1;hp=05f2fa0fbffeb00886a99a436f627f7e9525a8cf;hb=76cbed11b16936a77f4c41d72ce04fb11df5d7d1;hpb=48537c783a8d9769e005719f1268f83b1598e09e diff --git a/citadel/user_ops.c b/citadel/user_ops.c index 05f2fa0fb..607f16b3a 100644 --- a/citadel/user_ops.c +++ b/citadel/user_ops.c @@ -654,11 +654,7 @@ void do_login(void) /* If the user does not have any email addresses assigned, generate one. */ if (IsEmptyStr(CC->user.emailaddrs)) { - char synthetic_email_addr[1024]; - snprintf(synthetic_email_addr, sizeof synthetic_email_addr, "ctdl%08lx@%s", CC->user.usernum, CtdlGetConfigStr("c_fqdn")); - CtdlSetEmailAddressesForUser(CC->user.fullname, synthetic_email_addr); - strncpy(CC->user.emailaddrs, synthetic_email_addr, sizeof(CC->user.emailaddrs)); - syslog(LOG_DEBUG, "user_ops: auto-generated email address <%s> for <%s>", synthetic_email_addr, CC->user.fullname); + AutoGenerateEmailAddressForUser(&CC->user); } /*