[illumos-Developer] webrev: 374 cron should send more useful mail

Joshua M. Clulow josh at sysmgr.org
Tue Oct 26 04:10:35 PDT 2010


On Tue, Oct 26, 2010 at 8:00 PM, Joerg Schilling
<Joerg.Schilling at fokus.fraunhofer.de> wrote:
> strdup() is a really bad idea!
> Better use xstrdup()

Actually in this particular case strdup() failing would result in
rp->subject being set NULL which is the later-checked value that
represents "no MAIL_SUBJECT= defined" causing a fallback to the
auto-generated Subject: string.

> I have headaches with this solution. It is not clean but rather rapes a method
> that was introduced in order to set up job independent environment variables
> for the current cron user.

Seriously, it "rapes" cron?  How about "uses somewhat inconsistently"
or something slightly less emotional.

Also, how would you prefer we specify alternative subject?  I'm open
to constructive suggestions, but I also don't want to be working on
this RFE for the rest of my life and I think that this change is
backwards compatible and useful.  Not all environment variables can
presently be specified in crontabs anyway -- just HOME, TZ and SHELL.

-- 
Joshua M. Clulow
UNIX Admin/Developer
http://blog.sysmgr.org



More information about the Developer mailing list