diff --git a/newlib/ChangeLog b/newlib/ChangeLog index a90fcc2ca..82723087d 100644 --- a/newlib/ChangeLog +++ b/newlib/ChangeLog @@ -1,3 +1,8 @@ +2005-01-19 Shaun Jackman + + * libc/stdlib/setenv_r.c (_setenv_r): Call tzset() if the TZ + environment variable is set. + 2005-01-19 Shaun Jackman * tzset_r.c (_tzname): Add a comma. 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;