diff options
Diffstat (limited to 'osdep/getch2-os2.c')
-rw-r--r-- | osdep/getch2-os2.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/osdep/getch2-os2.c b/osdep/getch2-os2.c index c470743e14..27ebfaa354 100644 --- a/osdep/getch2-os2.c +++ b/osdep/getch2-os2.c @@ -26,6 +26,7 @@ #include <os2.h> #include <stdio.h> +#include <string.h> #include "config.h" #include "keycodes.h" @@ -190,7 +191,7 @@ char *get_term_charset( void ) #ifdef HAVE_LANGINFO setlocale( LC_CTYPE, ""); - charset = nl_langinfo( CODESET ); + charset = strdup( nl_langinfo( CODESET )); setlocale( LC_CTYPE, "C"); #endif |