Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/newlib
diff options
context:
space:
mode:
authorJeff Johnston <jjohnstn@redhat.com>2005-01-20 20:31:04 +0300
committerJeff Johnston <jjohnstn@redhat.com>2005-01-20 20:31:04 +0300
commit524298079ce052751ed305ade748f9d61e9b07db (patch)
tree2cc2e6c4ec9dab6a48b9335bd5b99c9039a121ea /newlib
parent1a0b5b8e6c23ad9744d99412fecfda80949d447e (diff)
2005-01-19 Shaun Jackman <sjackman@gmail.com>
* libc/stdlib/setenv_r.c (_setenv_r): Call tzset() if the TZ environment variable is set.
Diffstat (limited to 'newlib')
-rw-r--r--newlib/ChangeLog5
-rw-r--r--newlib/libc/stdlib/setenv_r.c2
2 files changed, 6 insertions, 1 deletions
diff --git a/newlib/ChangeLog b/newlib/ChangeLog
index a90fcc2ca..82723087d 100644
--- a/newlib/ChangeLog
+++ b/newlib/ChangeLog
@@ -1,5 +1,10 @@
2005-01-19 Shaun Jackman <sjackman@gmail.com>
+ * libc/stdlib/setenv_r.c (_setenv_r): Call tzset() if the TZ
+ environment variable is set.
+
+2005-01-19 Shaun Jackman <sjackman@gmail.com>
+
* tzset_r.c (_tzname): Add a comma.
2005-01-18 Aldy Hernandez <aldyh@redhat.com>
diff --git a/newlib/libc/stdlib/setenv_r.c b/newlib/libc/stdlib/setenv_r.c
index f06dc6772..694bd14a9 100644
--- a/newlib/libc/stdlib/setenv_r.c
+++ b/newlib/libc/stdlib/setenv_r.c
@@ -122,7 +122,7 @@ _DEFUN (_setenv_r, (reent_ptr, name, value, rewrite),
ENV_UNLOCK;
/* if we are setting the TZ environment variable, update timezone info */
- if (strcmp (name, "TZ") == 0)
+ if (strncmp ((*p_environ)[offset], "TZ=", 3) == 0)
tzset ();
return 0;