[tz] [PROPOSED 8/9] Port localtime.c timeoff to OpenBSD 7.4

Paul Eggert eggert at cs.ucla.edu
Thu Dec 21 01:29:54 UTC 2023


* localtime.c (timeoff): Define to my_timeoff if timeoff should be
static, to avoid colliding with <time.h>'s extern decl for timeoff
in OpenBSD 7.4.
---
 localtime.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/localtime.c b/localtime.c
index 1aee054f..c2cebfde 100644
--- a/localtime.c
+++ b/localtime.c
@@ -2293,6 +2293,9 @@ timelocal(struct tm *tmp)
 	return mktime(tmp);
 }
 #else
+# ifndef timeoff
+#  define timeoff my_timeoff /* Don't collide with OpenBSD 7.4 <time.h>.  */
+# endif
 static
 #endif
 /* This function is obsolescent and may disapper in future releases.
-- 
2.43.0




More information about the tz mailing list