bugGNU Mailutils - Bugs: bug #61239, Timezone offset in date header...

 
 

bug #61239: Timezone offset in date header weirdness when sendmail mail

Submitted by:  None
Submitted on:  Tue 28 Sep 2021 07:43:03 PM UTC  
 
Category:  None Severity:  3 - Normal
Item Group:  None Status:  Fixed
Privacy:  Public Assigned to:  Sergey Poznyakoff <gray>
Open/Closed:  Open

Add a New Comment (Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Thu 30 Sep 2021 04:23:42 AM UTC, comment #1: 
Sergey Poznyakoff <gray>
Project AdministratorIn charge of this item.
Tue 28 Sep 2021 07:43:03 PM UTC, original submission:  

The introduction of message_add_date in GNU Mailutils 3.13, may lead to weirdness in the timezone offset in Date headers added when sending messages (eg "Date: Sat, 7 Aug 2021 23:00:01 +4400"). I believe the problem arises in mu_utc_offset() in libmailutils/datetime/utcoff.c when the day (or month or year) of the GMT date differs from that of the localtime date.

For example, consider a message being sent at 2005 EDT / 0005 UTC. In mu_utc_offset, TMSEC(&ltm) equals 72300 and TMSEC(&gtm) equals  300. Initially, d is assigned 72000. But since ltm.tm_mday does not equal gtm.tm_mday, the function adds a day's worth of seconds to it and returns 158400. And in turn, mu_c_streamftime() generates the timezone offset in the date header by converting that to hours (44 = 158400/(60*60)) and minutes (0 = (158400/60)%60).

Anonymous

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by gray (Posted a comment)
  •  

    Do you think this task is very important?
    If so, you can add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

     

     

    Follow 2 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2021-09-30 gray StatusNone => Fixed
        Assigned toNone => gray

    Back to the top


    Powered by Savane 3.7