diff options
Diffstat (limited to 'src/llthread.c')
-rw-r--r-- | src/llthread.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/llthread.c b/src/llthread.c index 668a8c8..88498a8 100644 --- a/src/llthread.c +++ b/src/llthread.c | |||
@@ -228,6 +228,11 @@ static int llthread_copy_value(llthread_copy_state *state, int depth, int idx) { | |||
228 | } | 228 | } |
229 | break; | 229 | break; |
230 | case LUA_TFUNCTION: | 230 | case LUA_TFUNCTION: |
231 | if(lua_iscfunction(state->from_L, idx)){ | ||
232 | lua_CFunction fn = lua_tocfunction(state->from_L, idx); | ||
233 | lua_pushcfunction(state->to_L, fn); | ||
234 | break; | ||
235 | } | ||
231 | case LUA_TUSERDATA: | 236 | case LUA_TUSERDATA: |
232 | case LUA_TTHREAD: | 237 | case LUA_TTHREAD: |
233 | default: | 238 | default: |