aboutsummaryrefslogtreecommitdiff
path: root/lib/libc/locale
diff options
context:
space:
mode:
authorJordan K. Hubbard <jkh@FreeBSD.org>2003-12-22 20:45:16 +0000
committerJordan K. Hubbard <jkh@FreeBSD.org>2003-12-22 20:45:16 +0000
commit287e017d284c0a3e6a1c3afd360cf11d5576d6d7 (patch)
tree20912a87bfd31a1cd4e0d57b99f7925f0223374f /lib/libc/locale
parentbf45d2ea12d1ab43db1b08955a0bc420131e396c (diff)
Notes
Diffstat (limited to 'lib/libc/locale')
-rw-r--r--lib/libc/locale/ldpart.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/lib/libc/locale/ldpart.c b/lib/libc/locale/ldpart.c
index 564ad6e8145d..90d395b874e8 100644
--- a/lib/libc/locale/ldpart.c
+++ b/lib/libc/locale/ldpart.c
@@ -44,7 +44,7 @@ static int split_lines(char *, const char *);
int
__part_load_locale(const char *name,
int *using_locale,
- char *locale_buf,
+ char **locale_buf,
const char *category_filename,
int locale_buf_size_max,
int locale_buf_size_min,
@@ -66,7 +66,7 @@ __part_load_locale(const char *name,
/*
* If the locale name is the same as our cache, use the cache.
*/
- if (locale_buf != NULL && strcmp(name, locale_buf) == 0) {
+ if (*locale_buf != NULL && strcmp(name, *locale_buf) == 0) {
*using_locale = 1;
return (_LDP_CACHE);
}
@@ -121,10 +121,10 @@ __part_load_locale(const char *name,
/*
* Record the successful parse in the cache.
*/
- if (locale_buf != NULL)
- free(locale_buf);
- locale_buf = lbuf;
- for (p = locale_buf, i = 0; i < num_lines; i++)
+ if (*locale_buf != NULL)
+ free(*locale_buf);
+ *locale_buf = lbuf;
+ for (p = *locale_buf, i = 0; i < num_lines; i++)
dst_localebuf[i] = (p += strlen(p) + 1);
for (i = num_lines; i < locale_buf_size_max; i++)
dst_localebuf[i] = NULL;