From: Hristian Kirtchev Date: Thu, 23 Oct 2014 10:33:06 +0000 (+0000) Subject: sysdep.c (__gnat_localtime_tzoff): Properly delimit the substring which represents... X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=e776d44161b0e8e5d1248db4f0ccecff1b01914c;p=gcc.git sysdep.c (__gnat_localtime_tzoff): Properly delimit the substring which represents the time zone on VxWorks. 2014-10-23 Hristian Kirtchev * sysdep.c (__gnat_localtime_tzoff): Properly delimit the substring which represents the time zone on VxWorks. From-SVN: r216586 --- diff --git a/gcc/ada/ChangeLog b/gcc/ada/ChangeLog index 38edfbe0730..88bfeb73b02 100644 --- a/gcc/ada/ChangeLog +++ b/gcc/ada/ChangeLog @@ -1,3 +1,8 @@ +2014-10-23 Hristian Kirtchev + + * sysdep.c (__gnat_localtime_tzoff): Properly delimit the + substring which represents the time zone on VxWorks. + 2014-10-23 Vincent Celier * gnatls.adb: If --RTS= was not used, check if there is a default diff --git a/gcc/ada/sysdep.c b/gcc/ada/sysdep.c index bdda22cc69f..0ae05e06b1d 100644 --- a/gcc/ada/sysdep.c +++ b/gcc/ada/sysdep.c @@ -866,7 +866,7 @@ __gnat_localtime_tzoff (const time_t *timer ATTRIBUTE_UNUSED, tz_start = index (tz_str, ':') + 2; tz_end = index (tz_start, ':'); - tz_end = '\0'; + *tz_end = '\0'; /* The Ada layer expects an offset in seconds. Note that we must reverse the sign of the result since west is positive and east is negative on