From 926c3ce35a7ef910c55cf0964c39718ef5938ca6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dagfinn=20Ilmari=20Manns=C3=A5ker?= Date: Tue, 16 Jun 2020 13:47:35 +0100 Subject: time64: declare `tm_zone` as `const char*` unconditionally We only ever assign from `struct tm` to `struct TM`, not the other way around, so making this const regardless of what `struct tm` has should be safe. --- time64.h | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) (limited to 'time64.h') diff --git a/time64.h b/time64.h index b86e771602..8064ae7cf1 100644 --- a/time64.h +++ b/time64.h @@ -28,15 +28,7 @@ struct TM64 { #endif #ifdef HAS_TM_TM_ZONE -/* If glibc is defined or we are on QNX, use const. - * Otherwise, if we are on android, use const but - * not with g++. - */ -# if defined(__GLIBC__) || (defined(__ANDROID__) && !defined(__cplusplus)) \ - || defined(__QNX__) || defined(__CYGWIN__) - const -# endif - char *tm_zone; + const char *tm_zone; #endif }; -- cgit v1.2.1