Skip to content

Assertion SDL_HashTableEmpty fails on quit with (disconnected) PS4 controller reported in Windows #13129

Closed
@samgubernick

Description

@samgubernick

Not sure how much of an issue this is for SDL3 3.2.14 but Windows is reporting that a previously connected PS4 controller is still connected (Bluetooth). When I launch my program, SDL3 is trying to connect it, which fails, and then it disconnects it. Everything's fine till I call SDL_Quit(), which causes the following assertion to fail:

void SDL_SetObjectsInvalid(void)
{
    if (SDL_ShouldQuit(&SDL_objects_init)) {
        // Log any leaked objects
        SDL_IterateHashTable(SDL_objects, LogOneLeakedObject, NULL);
        SDL_assert(SDL_HashTableEmpty(SDL_objects)); // this is failing

I have no idea why Windows is reporting my controller's still connected, so I imagine there's a bigger issue in Windows and this is largely irrelevant, but I wanted to report this in case there's a separate issue in SDL3 where it isn't cleaning up the disconnected controllers correctly.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions