From 84f65f7ce32eeece9c3a8ecd4df03be1120f0c6b Mon Sep 17 00:00:00 2001 From: George Koehler Date: Fri, 22 Mar 2019 14:35:07 -0400 Subject: [PATCH] Raise _XOPEN_SOURCE from 500 to 700 In OpenBSD, _XOPEN_SOURCE 500 forces _POSIX_C_SOURCE down to 199506, which hides the declarations of openat() and fdopendir() and causes compiler warnings. Don't set _POSIX_C_SOURCE, because _XOPEN_SOURCE may set _POSIX_C_SOURCE to a different value. --- plat/cpm/emu/fileio.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/plat/cpm/emu/fileio.c b/plat/cpm/emu/fileio.c index a193805eb..d3df45785 100644 --- a/plat/cpm/emu/fileio.c +++ b/plat/cpm/emu/fileio.c @@ -1,5 +1,4 @@ -#define _XOPEN_SOURCE 500 -#define _POSIX_C_SOURCE 200809 +#define _XOPEN_SOURCE 700 #include #include #include @@ -440,4 +439,4 @@ int file_rename(cpm_filename_t* src, cpm_filename_t* dest) int drivefd = get_drive_fd(src); return renameat(drivefd, srcunixfilename, drivefd, destunixfilename); -} \ No newline at end of file +}