aboutsummaryrefslogtreecommitdiff
path: root/time/tzfile.c
diff options
context:
space:
mode:
Diffstat (limited to 'time/tzfile.c')
-rw-r--r--time/tzfile.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/time/tzfile.c b/time/tzfile.c
index e063d5d..663c02f 100644
--- a/time/tzfile.c
+++ b/time/tzfile.c
@@ -119,6 +119,7 @@ __tzfile_read (const char *file)
directory hierachy starting at TZDIR. */
if (__libc_enable_secure
&& ((*file == '/'
+ && (memcmp(file, TZDEFAULT, sizeof(TZDEFAULT) -1))
&& memcmp (file, default_tzdir, sizeof (default_tzdir) - 1))
|| strstr (file, "../") != NULL))
/* This test a certainly a bit too restrictive but it should