Skip to content

call_lua_direct with REF_IDX incorrectly pushes argument to lua_call #32

Description

@ma-bo

For example, on line winapi.c:2080
lcb_call(parms,-1,0,REF_IDX); // pass it a new File reference

In wutils.c:119
BOOL call_lua_direct(lua_State *L, Ref ref, int idx, const char *text, int flags) {
if (flags & REF_IDX)
lua_pushvalue(L,idx);

idx == -1, but push_ref(L,ref) pushes the function to the top of the stack, making lua_pushvalue(L,idx) incorrect.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions