nmh-workers
[Top] [All Lists]

[Nmh-workers] Removing Call to dlocaltimenow() in sortm(1).

2017-04-23 03:48:18
Hi,

I committed 62ee157e2dd14a1aec566d0370a1275654abd143.

    uip/sortm.c: Remove unused variable and dlocaltimenow() call.

    read_hdrs() has a auto `struct tws tb'.  It's only use is as the
    destination for dlocaltimenow()'s result.  Remove the variable.  Also
    remove the dlocaltimenow() call;  this I'm unsure about as it has a
    side effect of calling tzset(3).  However, tests pass.  Repository
    history sheds no light.

The diff is

     read_hdrs (struct msgs *mp, char *datesw)
     {
         int msgnum;
    -    struct tws tb;
         struct smsg *s;
     
    -    twscopy (&tb, dlocaltimenow ());
    -
         smsgs = mh_xcalloc(mp->hghsel - mp->lowsel + 2, sizeof *smsgs);
         s = smsgs;
         for (msgnum = mp->lowsel; msgnum <= mp->hghsel; msgnum++) {

I'm raising it here in case anyone has wounds from the code implicitly
expecting tzset(3) calls to happen in the past.

-- 
Cheers, Ralph.
https://plus.google.com/+RalphCorderoy

_______________________________________________
Nmh-workers mailing list
Nmh-workers(_at_)nongnu(_dot_)org
https://lists.nongnu.org/mailman/listinfo/nmh-workers

<Prev in Thread] Current Thread [Next in Thread>
  • [Nmh-workers] Removing Call to dlocaltimenow() in sortm(1)., Ralph Corderoy <=