aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>2003-07-07 10:34:25 -0300
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>2003-07-07 10:34:25 -0300
commita73ded21535c79a081cae16b12482e3e70441e6c (patch)
treec659561829a0911e093c0e9d748b1da3812e073e
parent0ec4c473df871ce88d3c06f7a801c557cb7f9d86 (diff)
downloadlua-a73ded21535c79a081cae16b12482e3e70441e6c.tar.gz
lua-a73ded21535c79a081cae16b12482e3e70441e6c.tar.bz2
lua-a73ded21535c79a081cae16b12482e3e70441e6c.zip
Move nothing when there is nothing to move
-rw-r--r--lapi.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/lapi.c b/lapi.c
index f5deadc8..e3c4b088 100644
--- a/lapi.c
+++ b/lapi.c
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: lapi.c,v 1.238 2003/05/09 20:16:54 roberto Exp roberto $ 2** $Id: lapi.c,v 1.239 2003/05/14 21:06:56 roberto Exp roberto $
3** Lua API 3** Lua API
4** See Copyright Notice in lua.h 4** See Copyright Notice in lua.h
5*/ 5*/
@@ -96,6 +96,7 @@ LUA_API int lua_checkstack (lua_State *L, int size) {
96 96
97LUA_API void lua_xmove (lua_State *from, lua_State *to, int n) { 97LUA_API void lua_xmove (lua_State *from, lua_State *to, int n) {
98 int i; 98 int i;
99 if (from == to) return;
99 lua_lock(to); 100 lua_lock(to);
100 api_checknelems(from, n); 101 api_checknelems(from, n);
101 from->top -= n; 102 from->top -= n;