@@ -4149,16 +4149,16 @@ ex_checktime(exarg_T *eap)
41494149#if (defined(HAVE_LOCALE_H ) || defined(X_LOCALE )) \
41504150 && (defined(FEAT_EVAL ) || defined(FEAT_MULTI_LANG ))
41514151# define HAVE_GET_LOCALE_VAL
4152- static char * get_locale_val (int what );
4152+ static char_u * get_locale_val (int what );
41534153
4154- static char *
4154+ static char_u *
41554155get_locale_val (int what )
41564156{
4157- char * loc ;
4157+ char_u * loc ;
41584158
41594159 /* Obtain the locale value from the libraries. For DJGPP this is
41604160 * redefined and it doesn't use the arguments. */
4161- loc = setlocale (what , NULL );
4161+ loc = ( char_u * ) setlocale (what , NULL );
41624162
41634163# ifdef WIN32
41644164 if (loc != NULL )
@@ -4222,7 +4222,7 @@ gettext_lang(char_u *name)
42224222
42234223 for (i = 0 ; mtable [i ] != NULL ; i += 2 )
42244224 if (STRNICMP (mtable [i ], name , STRLEN (mtable [i ])) == 0 )
4225- return mtable [i + 1 ];
4225+ return ( char_u * ) mtable [i + 1 ];
42264226 return name ;
42274227}
42284228#endif
@@ -4239,13 +4239,13 @@ get_mess_lang(void)
42394239
42404240# ifdef HAVE_GET_LOCALE_VAL
42414241# if defined(LC_MESSAGES )
4242- p = ( char_u * ) get_locale_val (LC_MESSAGES );
4242+ p = get_locale_val (LC_MESSAGES );
42434243# else
42444244 /* This is necessary for Win32, where LC_MESSAGES is not defined and $LANG
42454245 * may be set to the LCID number. LC_COLLATE is the best guess, LC_TIME
42464246 * and LC_MONETARY may be set differently for a Japanese working in the
42474247 * US. */
4248- p = ( char_u * ) get_locale_val (LC_COLLATE );
4248+ p = get_locale_val (LC_COLLATE );
42494249# endif
42504250# else
42514251 p = mch_getenv ((char_u * )"LC_ALL" );
@@ -4290,7 +4290,7 @@ get_mess_env(void)
42904290 p = NULL ; /* ignore something like "1043" */
42914291# ifdef HAVE_GET_LOCALE_VAL
42924292 if (p == NULL || * p == NUL )
4293- p = ( char_u * ) get_locale_val (LC_CTYPE );
4293+ p = get_locale_val (LC_CTYPE );
42944294# endif
42954295 }
42964296 }
@@ -4310,7 +4310,7 @@ set_lang_var(void)
43104310 char_u * loc ;
43114311
43124312# ifdef HAVE_GET_LOCALE_VAL
4313- loc = ( char_u * ) get_locale_val (LC_CTYPE );
4313+ loc = get_locale_val (LC_CTYPE );
43144314# else
43154315 /* setlocale() not supported: use the default value */
43164316 loc = (char_u * )"C" ;
@@ -4320,14 +4320,14 @@ set_lang_var(void)
43204320 /* When LC_MESSAGES isn't defined use the value from $LC_MESSAGES, fall
43214321 * back to LC_CTYPE if it's empty. */
43224322# if defined(HAVE_GET_LOCALE_VAL ) && defined(LC_MESSAGES )
4323- loc = ( char_u * ) get_locale_val (LC_MESSAGES );
4323+ loc = get_locale_val (LC_MESSAGES );
43244324# else
43254325 loc = get_mess_env ();
43264326# endif
43274327 set_vim_var_string (VV_LANG , loc , -1 );
43284328
43294329# ifdef HAVE_GET_LOCALE_VAL
4330- loc = ( char_u * ) get_locale_val (LC_TIME );
4330+ loc = get_locale_val (LC_TIME );
43314331# endif
43324332 set_vim_var_string (VV_LC_TIME , loc , -1 );
43334333}
0 commit comments