@@ -33,7 +33,7 @@
#include <timezone/tzfile.h>
-int __use_tzfile;
+bool __use_tzfile;
static dev_t tzfile_dev;
static ino64_t tzfile_ino;
static __time64_t tzfile_mtime;
@@ -147,14 +147,14 @@ __tzfile_read (const char *file)
union { struct tzhead tzhead; tzidx tzidx_aligned; } u;
tzidx charcnt;
tzidx i;
- int was_using_tzfile = __use_tzfile;
+ bool was_using_tzfile = __use_tzfile;
int trans_width = 4;
char *new = NULL;
_Static_assert (sizeof (__time64_t) == 8,
"__time64_t must be eight bytes");
- __use_tzfile = 0;
+ __use_tzfile = false;
if (file == NULL)
/* No user specification; use the site-wide default. */
@@ -565,8 +565,8 @@ __tzfile_read (const char *file)
__timezone = -rule_stdoff;
done:
- __use_tzfile = 1;
free (new);
+ __use_tzfile = true;
return;
lose:
@@ -8,7 +8,7 @@
/* Defined in tzset.c. */
extern char *__tzstring (const char *string) attribute_hidden;
-extern int __use_tzfile attribute_hidden;
+extern bool __use_tzfile attribute_hidden;
extern void __tzfile_read (const char *file) attribute_hidden;
extern void __tzfile_compute (__time64_t timer, int use_localtime,