Fix more sprintf calls.

This commit is contained in:
Marc Balmer
2012-08-09 07:38:39 +02:00
committed by Jon Trulson
parent 24c0f2010c
commit 1d935059fb
5 changed files with 22 additions and 20 deletions

View File

@@ -44,7 +44,7 @@ set_timezone(char *tzname)
if (tzname==NULL)
system("unset TZ\n");
else {
sprintf(tzenv, "TZ=%s", tzname);
snprintf(tzenv, sizeof tzenv, "TZ=%s", tzname);
(void) putenv(tzenv);
tzset();
}