* cmd.c (guess_message_value): Remove the argument. Adjust all

callers.
This commit is contained in:
Pavel Roskin 2001-09-16 00:18:39 +00:00
parent e94ec737ad
commit 7fe30fff07
4 changed files with 12 additions and 17 deletions

View File

@ -1,5 +1,8 @@
2001-09-15 Pavel Roskin <proski@gnu.org>
* cmd.c (guess_message_value): Remove the argument. Adjust all
callers.
* textconf.c (features): Remove "edition", minor fixes.
(version): Don't report the current locale - it's meaningless,
especially if ENABLE_NLS is not defined.

View File

@ -1191,7 +1191,7 @@ void mkdir_panel_cmd (void)
/* partly taken from dcigettext.c, returns "" for default locale */
/* value should be freed by calling function g_free() */
char *guess_message_value (unsigned want_info)
char *guess_message_value (void)
{
const char *var[] = {
/* The highest priority value is the `LANGUAGE' environment
@ -1219,18 +1219,10 @@ char *guess_message_value (unsigned want_info)
i++;
}
if (var[i] == NULL)
if (locale == NULL)
locale = "";
if (want_info == 0)
retval = g_strdup (locale);
else
if (var[i] == NULL)
retval = g_strdup (_("Using default locale"));
else
retval = g_strdup_printf (_("Using locale \"%s\" (from environment variable %s)"), locale, var[i]);
return retval;
return g_strdup (locale);
}
/* Returns a random hint */

View File

@ -63,7 +63,7 @@ void save_setup_cmd (void);
char *get_random_hint (void);
void source_routing (void);
void user_file_menu_cmd (void);
char *guess_message_value (unsigned want_info);
char *guess_message_value (void);
int check_for_default(char *default_file, char *file);
/* Display mode code */

View File

@ -628,7 +628,7 @@ char *load_mc_home_file (const char *filename, char ** allocated_filename)
char *data;
hintfile_base = concat_dir_and_file (mc_home, filename);
lang = guess_message_value (0);
lang = guess_message_value ();
hintfile = g_strdup_printf ("%s.%s", hintfile_base, lang);
data = load_file (hintfile);