From c0dde461aa23e95dacf6dbdb0a489e37c399fbf6 Mon Sep 17 00:00:00 2001 From: P. J. McDermott Date: Tue, 25 Aug 2015 13:15:32 -0400 Subject: src/scripting/ffi.c: Fix variable --- diff --git a/src/scripting/ffi.c b/src/scripting/ffi.c index 9029b25..a7e9834 100644 --- a/src/scripting/ffi.c +++ b/src/scripting/ffi.c @@ -119,7 +119,7 @@ ffi_register_functions_in_namespace(lua_State *l, struct ffi_namespace *parent) lua_setfield(l, -1, ns->name); } } - for (fn = ns->fn_head; fn != NULL; fn = fn->next) { + for (fn = parent->fn_head; fn != NULL; fn = fn->next) { lua_pushlightuserdata(l, fn); lua_pushcclosure(l, &ffi_handle_function, 1); lua_setfield(l, -2, fn->name); -- cgit v0.9.1