Explorar o código

Fix stack growth for coroutine.wrap().

Mike Pall %!s(int64=15) %!d(string=hai) anos
pai
achega
5baf0f9dc2
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      src/lib_base.c

+ 1 - 1
src/lib_base.c

@@ -498,7 +498,7 @@ static int ffh_resume(lua_State *L, lua_State *co, int wrap)
     setstrV(L, L->base, lj_err_str(L, em));
     return FFH_RES(2);
   }
-  lj_state_growstack(co, (MSize)(L->top - L->base - 1));
+  lj_state_growstack(co, (MSize)(L->top - L->base));
   return FFH_RETRY;
 }