A NOTE has been added to this issue. 
====================================================================== 
https://austingroupbugs.net/view.php?id=1797 
====================================================================== 
Reported By:                eggert
Assigned To:                
====================================================================== 
Project:                    Issue 8 drafts
Issue ID:                   1797
Category:                   System Interfaces
Type:                       Error
Severity:                   Objection
Priority:                   normal
Status:                     New
Name:                       Paul Eggert 
Organization:               UCLA Computer Science Dept. 
User Reference:             strftime-%s 
Section:                    strftime 
Page Number:                2136 
Line Number:                69836-69837 
Final Accepted Text:         
====================================================================== 
Date Submitted:             2024-01-15 23:56 UTC
Last Modified:              2024-03-11 09:55 UTC
====================================================================== 
Summary:                    strftime "%s" should be able to examine tm_gmtoff
======================================================================
Relationships       ID      Summary
----------------------------------------------------------------------
related to          0001533 struct tm: add tm_gmtoff (and tm_zone) ...
related to          0001816 daylight, timezone, tzname do not work ...
child of            0001612 XSH strftime() new (I8) %s conversion r...
child of            0000169 date utility needs ``%s''
====================================================================== 

---------------------------------------------------------------------- 
 (0006718) geoffclare (manager) - 2024-03-11 09:55
 https://austingroupbugs.net/view.php?id=1797#c6718 
---------------------------------------------------------------------- 
> I suppose we could say that GNU/Linux, FreeBSD, and pretty much everyone
else is broken. But it’s better to be realistic and tell users that when
using strftime’s %z, %Z and %s formats, tm_zone and tm_gmtoff must be set
to in-range values.

For %z and %Z, requiring applications to set tm_zone and tm_gmtoff would
create a conflict with the C standard. C17 says that the only member used
by %z and %Z is tm_isdst.

Of course, if an application explicitly sets tm_zone or tm_gmtoff then it
is using an extension to C17 and this could alter the behaviour, and if the
structure was populated by localtime() et al then use of tm_zone or
tm_gmtoff can be an internal implementation detail, as per my previous
note. However, the crucial case is when the application populates the
structure in a way that does not set tm_zone or tm_gmtoff; for this case
C17 requires that the conversion is done based on tm_isdst. 

Issue History 
Date Modified    Username       Field                    Change               
====================================================================== 
2024-01-15 23:56 eggert         New Issue                                    
2024-01-15 23:56 eggert         Name                      => Paul Eggert     
2024-01-15 23:56 eggert         Organization              => UCLA Computer
Science Dept.
2024-01-15 23:56 eggert         User Reference            => strftime-%s     
2024-01-15 23:56 eggert         Section                   => strftime        
2024-01-15 23:56 eggert         Page Number               => 2136            
2024-01-15 23:56 eggert         Line Number               => 69836-69837     
2024-01-16 01:29 steffen        Note Added: 0006623                          
2024-01-16 01:42 steffen        Note Added: 0006624                          
2024-01-16 01:42 steffen        Note Deleted: 0006623                        
2024-02-01 16:42 nick           Relationship added       related to 0001533  
2024-02-12 16:11 eblake         Note Added: 0006651                          
2024-02-25 06:50 kre            Note Added: 0006677                          
2024-02-25 06:54 kre            Note Edited: 0006677                         
2024-02-26 18:28 eggert         Note Added: 0006688                          
2024-02-26 19:23 eblake         Relationship added       related to 0001816  
2024-02-26 19:32 eblake         Note Added: 0006689                          
2024-02-26 19:52 eblake         Relationship added       child of 0001612    
2024-02-26 19:55 eblake         Relationship added       child of 0000169    
2024-02-26 20:02 eblake         Note Added: 0006690                          
2024-02-29 12:10 geoffclare     Note Added: 0006691                          
2024-02-29 12:15 geoffclare     Note Added: 0006692                          
2024-02-29 16:19 shware_systems Note Added: 0006693                          
2024-03-01 10:09 geoffclare     Note Added: 0006698                          
2024-03-02 09:02 eggert         Note Added: 0006700                          
2024-03-03 01:20 kre            Note Added: 0006701                          
2024-03-07 10:44 geoffclare     Note Added: 0006706                          
2024-03-07 11:04 geoffclare     Note Added: 0006707                          
2024-03-11 09:55 geoffclare     Note Added: 0006718                          
======================================================================


  • [Issue 8 dra... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [Issue 8 dra... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [Issue 8 dra... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [Issue 8 dra... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [Issue 8 dra... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [Issue 8 dra... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [Issue 8 dra... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [Issue 8 dra... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [Issue 8 dra... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [Issue 8 dra... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [Issue 8 dra... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [Issue 8 dra... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [Issue 8 dra... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [Issue 8 dra... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [Issue 8 dra... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [Issue 8 dra... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [Issue 8 dra... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [Issue 8 dra... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [Issue 8 dra... Austin Group Bug Tracker via austin-group-l at The Open Group

Reply via email to