examples: Fix memory leaked by device discovery

https://bugs.freedesktop.org/show_bug.cgi?id=105427
This commit is contained in:
Mark Harfouche 2018-03-11 13:44:31 +01:00 committed by Bastien Nocera
parent 58ba9b02ed
commit 7ff667f58d

View file

@ -57,6 +57,7 @@ int main(void)
ddev = discover_device(discovered_devs);
if (!ddev) {
fp_dscv_devs_free(discovered_devs);
fprintf(stderr, "No devices detected.\n");
goto out;
}