size grow by 10x (from 28kB to 290kB). After searching a bit, I found that the responsible was the INIT() macro in globals.h \
which initializes huge strings MailCmd and cron_default_mail_charset both of which are 128 kB. Due to this initialization, the memory \
areas are stored for real in the binary, resulting in larger sizes
Signed-off-by: Marcela Mašláňová <mmaslano@redhat.com>
#endif
ProgramName = argv[0];
+ MailCmd[0] = '\0';
+ cron_default_mail_charset[0] = '\0';
setlocale(LC_ALL, "");
Pid = getpid();
ProgramName = argv[0];
+ MailCmd[0] = '\0';
+ cron_default_mail_charset[0] = '\0';
setlocale(LC_ALL, "");
#endif
;
-XTRN char *ProgramName INIT("amnesia");
+XTRN char *ProgramName;
XTRN int LineNumber INIT(0);
XTRN time_t StartTime INIT(0);
XTRN int NoFork INIT(0);
XTRN int PermitAnyCrontab INIT(0);
XTRN int ValidateMailRcpts INIT(0);
-XTRN char MailCmd[MAX_COMMAND] INIT("");
-XTRN char cron_default_mail_charset[MAX_ENVSTR] INIT("");
+XTRN char MailCmd[MAX_COMMAND];
+XTRN char cron_default_mail_charset[MAX_ENVSTR];
#if DEBUGGING
XTRN int DebugFlags INIT(0);