[[PATCH,RFC,2] 26/63] Y2038: add struct __itimerspec64

Message ID 20180418201819.15952-27-albert.aribaud@3adev.fr
State New, archived
Headers

Commit Message

Albert ARIBAUD April 18, 2018, 8:17 p.m. UTC
  ---
 time/bits/types/struct_itimerspec.h | 7 +++++++
 1 file changed, 7 insertions(+)
  

Comments

Joseph Myers April 18, 2018, 9:54 p.m. UTC | #1
On Wed, 18 Apr 2018, Albert ARIBAUD (3ADEV) wrote:

> ---
>  time/bits/types/struct_itimerspec.h | 7 +++++++
>  1 file changed, 7 insertions(+)
> 
> diff --git a/time/bits/types/struct_itimerspec.h b/time/bits/types/struct_itimerspec.h
> index 17cc1ac86d..1f8fff439f 100644
> --- a/time/bits/types/struct_itimerspec.h
> +++ b/time/bits/types/struct_itimerspec.h
> @@ -11,4 +11,11 @@ struct itimerspec
>      struct timespec it_value;
>    };
>  
> +/* 64-bit interval timer spec */
> +struct __itimerspec64
> +{
> +  struct __timespec64 it_interval;
> +  struct __timespec64 it_value;
> +};

No, bits/types/* are for exactly one type per header.  You need a separate 
bits/types/struct___itimerspec64.h to define struct __itimerspec64 (and 
likewise for any other such type, and with Makefiles modified to install 
any new such headers).
  

Patch

diff --git a/time/bits/types/struct_itimerspec.h b/time/bits/types/struct_itimerspec.h
index 17cc1ac86d..1f8fff439f 100644
--- a/time/bits/types/struct_itimerspec.h
+++ b/time/bits/types/struct_itimerspec.h
@@ -11,4 +11,11 @@  struct itimerspec
     struct timespec it_value;
   };
 
+/* 64-bit interval timer spec */
+struct __itimerspec64
+{
+  struct __timespec64 it_interval;
+  struct __timespec64 it_value;
+};
+
 #endif