diff options
author | Corinna Vinschen <corinna@vinschen.de> | 2016-10-23 16:45:21 +0200 |
---|---|---|
committer | Corinna Vinschen <corinna@vinschen.de> | 2016-10-23 16:45:21 +0200 |
commit | cf01b8f0290eacb35d2c5206b25d3b5968706445 (patch) | |
tree | deb43fbe1df5d54fcefe1328f3b07b88d976f4cc /winsup/utils | |
parent | 5e087a83734fac4674a45a8ca8dd7e8bb1eb5d5e (diff) | |
download | newlib-cf01b8f0290eacb35d2c5206b25d3b5968706445.zip newlib-cf01b8f0290eacb35d2c5206b25d3b5968706445.tar.gz newlib-cf01b8f0290eacb35d2c5206b25d3b5968706445.tar.bz2 |
tzset: Fix array length given to GetGeoInfoW
Fixes Coverity CID 66916
Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
Diffstat (limited to 'winsup/utils')
-rw-r--r-- | winsup/utils/tzset.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/winsup/utils/tzset.c b/winsup/utils/tzset.c index 02ac5f3..b7fd1ae 100644 --- a/winsup/utils/tzset.c +++ b/winsup/utils/tzset.c @@ -195,7 +195,7 @@ main (int argc, char **argv) *country = L'\0'; geo = GetUserGeoID (GEOCLASS_NATION); if (geo != GEOID_NOT_AVAILABLE) - GetGeoInfoW (geo, GEO_ISO2, country, sizeof country, 0); + GetGeoInfoW (geo, GEO_ISO2, country, sizeof country / sizeof (*country), 0); /* If, for some reason, the Geo-location isn't available, we use the locale setting instead. */ if (!*country) |