Bug #13327
openstruct timespec not POSIX compliant
0%
Description
The POSIX 2008 standard documents struct timespec with members tv_sec and tv_nsec. However, if standards are requested, these become __tv_sec and __tv_nsec on illumos derviates. There are comments in the relevant headers referring to the latter names as "standards namespace safe versions of these definitions"[1], but that doesn't make sense, as those member names don't comply with a defined standard. I realize that was done some time ago (2004 or earlier), and I understand that there may be legacy concerns that led to that approach originally being taken.
1. [[https://github.com/illumos/illumos-gate/blob/4e0c5eff9af325c80994e9527b7cb8b3a1ffd1d4/usr/src/uts/common/sys/stat.h#L42]]
and
[[https://github.com/illumos/illumos-gate/blob/4e0c5eff9af325c80994e9527b7cb8b3a1ffd1d4/usr/src/uts/common/sys/time_std_impl.h#L28]]
No data to display