Skip to content

Library name is incorrectly cleared on exit #12

@enyfpc

Description

@enyfpc

When calling HidExit(), function ReleaseHidApi() is also called.
This function clears the variable that holds the default library name:
HidApiLoadedLibrary := ''; // Line 308 in hidapi.inc

When in the same program the HID API functions are used again, i.e. the library is reloaded, this will fail because the library name is now gone.
Global variable HidApiLoadedLibrary is not re-initialized.

This should be replaced with setting the library to the global default value:
HidApiLoadedLibrary := LIBHIDAPI; // Line 308 in hidapi.inc

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