Include <kernel-features.h> explicitly in Linux clock_settime.c
diff mbox series

Message ID 20191018134601.2547-1-lukma@denx.de
State New
Headers show
Series
  • Include <kernel-features.h> explicitly in Linux clock_settime.c
Related show

Commit Message

Lukasz Majewski Oct. 18, 2019, 1:46 p.m. UTC
The rewritten clock_settime code (which now supports 64 bit time on systems
with __WORDSIZE == 32)  for Linux now relies on the
__ASSUME_TIME64_SYSCALLS flag set.

Lets explicitly include the header file where it is defined to avoid
any indirect inclusion (which may pose some unwanted API definitions).

Tested with scripts/build-many-glibcs.py script.
---
 sysdeps/unix/sysv/linux/clock_settime.c | 1 +
 1 file changed, 1 insertion(+)

Comments

Joseph Myers Oct. 18, 2019, 3:18 p.m. UTC | #1
On Fri, 18 Oct 2019, Lukasz Majewski wrote:

> The rewritten clock_settime code (which now supports 64 bit time on systems
> with __WORDSIZE == 32)  for Linux now relies on the
> __ASSUME_TIME64_SYSCALLS flag set.
> 
> Lets explicitly include the header file where it is defined to avoid
> any indirect inclusion (which may pose some unwanted API definitions).
> 
> Tested with scripts/build-many-glibcs.py script.

OK, please commit.

Patch
diff mbox series

diff --git a/sysdeps/unix/sysv/linux/clock_settime.c b/sysdeps/unix/sysv/linux/clock_settime.c
index fb48de5d50..54999d3008 100644
--- a/sysdeps/unix/sysv/linux/clock_settime.c
+++ b/sysdeps/unix/sysv/linux/clock_settime.c
@@ -19,6 +19,7 @@ 
 #include <sysdep.h>
 #include <time.h>
 #include <shlib-compat.h>
+#include <kernel-features.h>
 
 /* Set CLOCK to value TP.  */
 int