From 151697b99ea519d6ea867d979cbf84be565ba09a Mon Sep 17 00:00:00 2001 From: "p.kosyh" Date: Mon, 1 Feb 2010 15:37:51 +0000 Subject: [PATCH] broken codepage --- src/sdl-instead/instead.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/sdl-instead/instead.c b/src/sdl-instead/instead.c index 4fb7d05..8b4642f 100644 --- a/src/sdl-instead/instead.c +++ b/src/sdl-instead/instead.c @@ -79,7 +79,7 @@ char *getstring(char *cmd) if (dostring(L, cmd)) return NULL; N = lua_gettop(L); /* number of arguments */ - if (N <=0) + if (-N >=0) return NULL; s = (char*)lua_tostring(L, -N); if (s) @@ -239,6 +239,7 @@ int instead_load(char *game) if (dofile(L, game)) { return -1; } + instead_clear(); #ifdef _HAVE_ICONV if (fromcp) free(fromcp);