aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPaul Eggert2016-11-20 13:24:53 -0800
committerPaul Eggert2016-11-20 13:25:45 -0800
commit8a147fb24681cd5b89b99376c95baf785dd5126f (patch)
tree55339a3d1dbd83bc70689d8fc3797388524f7eef
parent7e2a8b17aea197f2b2609878180d281ac2dfe0d4 (diff)
downloademacs-8a147fb24681cd5b89b99376c95baf785dd5126f.tar.gz
emacs-8a147fb24681cd5b89b99376c95baf785dd5126f.zip
Pacify --enable-gcc-warnings CANNOT_DUMP=yes
* src/editfns.c (dump_tz_string) [CANNOT_DUMP || !HAVE_TZSET]: Do not define. If defining, do it in a smaller scope.
-rw-r--r--src/editfns.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/editfns.c b/src/editfns.c
index 72c7a9c27c9..6ea8cbaf5e4 100644
--- a/src/editfns.c
+++ b/src/editfns.c
@@ -87,10 +87,6 @@ static timezone_t local_tz;
87static timezone_t wall_clock_tz; 87static timezone_t wall_clock_tz;
88static timezone_t const utc_tz = 0; 88static timezone_t const utc_tz = 0;
89 89
90/* A valid but unlikely setting for the TZ environment variable.
91 It is OK (though a bit slower) if the user chooses this value. */
92static char dump_tz_string[] = "TZ=UtC0";
93
94/* The cached value of Vsystem_name. This is used only to compare it 90/* The cached value of Vsystem_name. This is used only to compare it
95 to Vsystem_name, so it need not be visible to the GC. */ 91 to Vsystem_name, so it need not be visible to the GC. */
96static Lisp_Object cached_system_name; 92static Lisp_Object cached_system_name;
@@ -230,6 +226,12 @@ tzlookup (Lisp_Object zone, bool settz)
230void 226void
231init_editfns (bool dumping) 227init_editfns (bool dumping)
232{ 228{
229#if !defined CANNOT_DUMP && defined HAVE_TZSET
230 /* A valid but unlikely setting for the TZ environment variable.
231 It is OK (though a bit slower) if the user chooses this value. */
232 static char dump_tz_string[] = "TZ=UtC0";
233#endif
234
233 const char *user_name; 235 const char *user_name;
234 register char *p; 236 register char *p;
235 struct passwd *pw; /* password entry for the current user */ 237 struct passwd *pw; /* password entry for the current user */