shared: time-dst - ensure nulstr is null terminated

Fixes CID #1237772.
This commit is contained in:
Tom Gundersen 2014-11-29 10:40:21 +01:00
parent 0acd5a08f5
commit 681f9718ce

View file

@ -244,6 +244,8 @@ read_again:
if (fread(zone_names, 1, chars, f) != chars)
return -EINVAL;
zone_names[chars] = '\0';
for (i = 0; i < num_isstd; ++i) {
int c = getc(f);
if (c == EOF)