/[man-db]/man-db/src/encodings.c
ViewVC logotype

Diff of /man-db/src/encodings.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.8 by cjwatson, Sun Sep 14 15:58:58 2003 UTC revision 1.9 by cjwatson, Sun Sep 14 16:49:03 2003 UTC
# Line 206  const char *get_source_encoding (const c Line 206  const char *get_source_encoding (const c
206          const struct directory_entry *entry;          const struct directory_entry *entry;
207          const char *dot;          const char *dot;
208    
209          if (!lang)          if (!lang || !*lang) {
210                  return fallback_source_encoding;                  /* Guess based on the locale. */
211                    lang = setlocale (LC_MESSAGES, NULL);
212                    if (!lang)
213                            return fallback_source_encoding;
214            }
215    
216          dot = strchr (lang, '.');          dot = strchr (lang, '.');
217          if (dot)          if (dot)
# Line 250  const char *get_standard_output_encoding Line 254  const char *get_standard_output_encoding
254          const struct directory_entry *entry;          const struct directory_entry *entry;
255          const char *dot;          const char *dot;
256    
257          if (!lang)          if (!lang || !*lang) {
258                  return NULL;                  /* Guess based on the locale. */
259                    lang = setlocale (LC_MESSAGES, NULL);
260                    if (!lang)
261                            return NULL;
262            }
263    
264          dot = strchr (lang, '.');          dot = strchr (lang, '.');
265          if (dot)          if (dot)

Legend:
Removed from v.1.8  
changed lines
  Added in v.1.9

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26