Skip to content

autodump hotkeys can run without acquiring a coresuspender under some conditions #5835

Description

@ab9rf

Hitting Alt-K while a designation is being selected and while a DFHack overlay window is open but not selected (e.g. gui/reveal) will cause an assertion failure in dfhack_lua_viewscreen::getSelected for attempting to acquire the shared Lua state without holding the core suspender.

Replication process: Open gui/reveal. Click outside the window to make it nonactive; do not close it. Press x to begin a "remove designation" operation. Click somewhere to start designating a rectangle to remove designations. Hit Ctrl-K to trigger the hotkey for autodump-destroy-item. A production instance will hang (presumably due to deadlock); a developer build will assertion-fail on the assertion in DFHack::Core::getInstance().getLuaState() that requires isSuspended() to be true.

See Discord for more context.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions