List Info

Thread: index_record sent_date




index_record sent_date
country flaguser name
United Kingdom
2007-12-28 10:22:08
Mostly idle curiosity:

Why is index_record.sent_date always set to midday on a
given day?

This is most obvious in the output from unexpunge -l:

         Sent: Fri Dec 21 12:00:00 2007  << This line
         Recv: Fri Dec 21 14:51:58 2007
         Expg: Fri Dec 28 16:01:58 2007

My first thought was that this was a bug in my new improved
reconstruct, 
but it turns out to just be the way message_parse_date()
calculates dates.

   time_t
   message_parse_date(hdr, flags)
   {
       /* ... */
       message_parse_rfc822space(&hdr);
       if (hdr && (flags & PARSE_TIME)) {
            /* ... */
       }
       else
    badtime:
            tm.tm_hour = 12;

As far as I can see from a quick grep, ipurge is the only
thing which uses 
sent_date. I don't use ipurge, so I may be missing some
subtlety.

-- 
David Carter                             Email:
David.Carterucs.cam.ac.uk
University Computing Service,            Phone: (01223)
334502
New Museums Site, Pembroke Street,       Fax:   (01223)
334679
Cambridge UK. CB2 3QH.

[1]

about | contact  Other archives ( Real Estate discussion Medical topics )