// headers
// ----------------------------------------------------------------------------
-#ifdef __EMX__
-// The following define is needed by Innotek's libc to
-// make the definition of struct localeconv available.
-#define __INTERNAL_DEFS
-#endif
-
// For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
#pragma hdrstop
#endif
+#ifdef __EMX__
+// The following define is needed by Innotek's libc to
+// make the definition of struct localeconv available.
+#define __INTERNAL_DEFS
+#endif
+
#if wxUSE_INTL
#ifndef WX_PRECOMP
#if defined(__UNIX__) && wxUSE_UNICODE && !defined(__WXMAC__)
static const char *wxSetlocaleTryUTF8(int c, const wxString& lc)
{
- const char *l;
+ const char *l = NULL;
// NB: We prefer to set UTF-8 locale if it's possible and only fall back to
// non-UTF-8 locale if it fails
//
// this contradicts IBM own docs but this is not of much help, so just work
// around it in the crudest possible manner
- char *p = wxStrchr(retloc, ' ');
+ char* p = const_cast<char*>(wxStrchr(retloc, ' '));
if ( p )
*p = '\0';
#endif // __AIX__