mirror of
https://github.com/libretro/RetroArch.git
synced 2025-04-02 10:51:52 -04:00
Merge pull request #1629 from lioncash/leak
libusb_hid: Fix a potential memory leak
This commit is contained in:
commit
e9dd1603ab
1 changed files with 1 additions and 0 deletions
|
@ -188,6 +188,7 @@ static int add_adapter(void *data, struct libusb_device *dev)
|
|||
|
||||
if (!adapter || !hid)
|
||||
{
|
||||
free(adapter);
|
||||
fprintf(stderr, "Allocation of adapter failed.\n");
|
||||
return -1;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue