From c107e96be21679b6ea64ae4c3df4b894d3f74eed Mon Sep 17 00:00:00 2001 From: =?utf8?q?Marcela=20Ma=C5=A1l=C3=A1=C5=88ov=C3=A1?= Date: Fri, 5 Jun 2009 14:36:55 +0200 Subject: [PATCH] ValidateMailRcpts removed for problems when could be enviromental settings exported under wrong user. --- src/cron.c | 3 --- src/do_command.c | 4 +--- src/globals.h | 1 - 3 files changed, 1 insertion(+), 7 deletions(-) diff --git a/src/cron.c b/src/cron.c index fea297a..c14aba5 100644 --- a/src/cron.c +++ b/src/cron.c @@ -177,9 +177,6 @@ int main(int argc, char *argv[]) { exit(1); } - if (getenv("CRON_VALIDATE_MAILRCPTS") != 0L) - ValidateMailRcpts = 1; - /* Get the default locale character set for the mail * "Content-Type: ...; charset=" header */ diff --git a/src/do_command.c b/src/do_command.c index 6a73410..b4917a1 100644 --- a/src/do_command.c +++ b/src/do_command.c @@ -369,9 +369,7 @@ static void child_process(entry * e, user * u) { * up the mail command and subjects and stuff... */ - if (mailto && ((ValidateMailRcpts == 0) || safe_p(usernm, mailto)) - /* Why validate the mail recipient name ? All mailers do this anyway... JVD */ - ) { + if (mailto && safe_p(usernm, mailto)) { char **env; char mailcmd[MAX_COMMAND]; char hostname[MAXHOSTNAMELEN]; diff --git a/src/globals.h b/src/globals.h index cdcf578..82e6980 100644 --- a/src/globals.h +++ b/src/globals.h @@ -64,7 +64,6 @@ XTRN int LineNumber; XTRN time_t StartTime; XTRN int NoFork; XTRN int PermitAnyCrontab; -XTRN int ValidateMailRcpts; XTRN char MailCmd[MAX_COMMAND]; XTRN char cron_default_mail_charset[MAX_ENVSTR]; -- 2.40.0