]> skyeroc.xyz Git - dgamelaunch/commitdiff
Exit ee gracefully, if character conversion fails.
authorPasi Kallinen <paxed@alt.org>
Fri, 16 May 2014 16:19:12 +0000 (19:19 +0300)
committerPasi Kallinen <paxed@alt.org>
Fri, 16 May 2014 16:19:12 +0000 (19:19 +0300)
ee.c

diff --git a/ee.c b/ee.c
index f8e0bed817627e5ec763dc7abb9fcc44dc3b7696..67acefbdfcfe5ea0bf1e88ccc43d215f969a5c98 100644 (file)
--- a/ee.c
+++ b/ee.c
@@ -1970,6 +1970,9 @@ int *append;      /* TRUE if must append more text to end of current line */
        wchar_t in_string[MAX_FILE];
        length = mbstowcs(in_string, in_str, sizeof(in_string));
 
+       if (length == -1)
+           exit(0);
+
        str2 = in_string;
        num = 0;
        first_time = TRUE;