aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--opcode.c13
1 files changed, 9 insertions, 4 deletions
diff --git a/opcode.c b/opcode.c
index c11cda3f..d6b9830a 100644
--- a/opcode.c
+++ b/opcode.c
@@ -3,7 +3,7 @@
3** TecCGraf - PUC-Rio 3** TecCGraf - PUC-Rio
4*/ 4*/
5 5
6char *rcs_opcode="$Id: opcode.c,v 3.57 1996/02/12 18:32:40 roberto Exp roberto $"; 6char *rcs_opcode="$Id: opcode.c,v 3.58 1996/02/22 20:34:33 roberto Exp roberto $";
7 7
8#include <setjmp.h> 8#include <setjmp.h>
9#include <stdlib.h> 9#include <stdlib.h>
@@ -784,9 +784,14 @@ void lua_pushnumber (real n)
784*/ 784*/
785void lua_pushstring (char *s) 785void lua_pushstring (char *s)
786{ 786{
787 tsvalue(top) = lua_createstring(s); 787 if (s == NULL)
788 tag(top) = LUA_T_STRING; 788 tag(top) = LUA_T_NIL;
789 incr_top; 789 else
790 {
791 tsvalue(top) = lua_createstring(s);
792 tag(top) = LUA_T_STRING;
793 }
794 incr_top;
790} 795}
791 796
792/* 797/*