aboutsummaryrefslogtreecommitdiff
path: root/time
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2007-10-16 22:37:35 +0000
committerUlrich Drepper <drepper@redhat.com>2007-10-16 22:37:35 +0000
commit69819d92239d4b8d7519a3cbcff0e2cab5906be3 (patch)
tree2a3184eb24c8f70c91b69d0ee27b018a25d99844 /time
parente2cceb5a74764ee34a2d84c0a875af9e381b99db (diff)
downloadglibc-69819d92239d4b8d7519a3cbcff0e2cab5906be3.zip
glibc-69819d92239d4b8d7519a3cbcff0e2cab5906be3.tar.gz
glibc-69819d92239d4b8d7519a3cbcff0e2cab5906be3.tar.bz2
(__tzfile_read): Take extra memory requested by caller into account when copying TZ string.
2007-10-16 Ulrich Drepper <drepper@redhat.com> * time/tzfile.c (__tzfile_read): Take extra memory requested by caller into account when copying TZ string.
Diffstat (limited to 'time')
-rw-r--r--time/tzfile.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/time/tzfile.c b/time/tzfile.c
index d16115f..925f95f 100644
--- a/time/tzfile.c
+++ b/time/tzfile.c
@@ -264,7 +264,7 @@ __tzfile_read (const char *file, size_t extra, char **extrap)
zone_names = (char *) types + num_types * sizeof (struct ttinfo);
leaps = (struct leap *) ((char *) transitions + leaps_idx);
if (trans_width == 8)
- tzspec = (char *) leaps + num_leaps * sizeof (struct leap);
+ tzspec = (char *) leaps + num_leaps * sizeof (struct leap) + extra;
else
tzspec = NULL;
if (extra > 0)