--- ldpart.c.orig Tue May 20 15:21:44 2003 +++ ldpart.c Wed Jun 11 13:11:52 2003 @@ -47,7 +47,7 @@ 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, @@ -69,7 +69,7 @@ /* * 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); } @@ -124,10 +124,10 @@ /* * 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;