ao-chaosread: Eliminate double-free when serial match fails
authorKeith Packard <keithp@keithp.com>
Tue, 2 Aug 2016 23:53:17 +0000 (16:53 -0700)
committerKeith Packard <keithp@keithp.com>
Tue, 2 Aug 2016 23:55:12 +0000 (16:55 -0700)
Signed-off-by: Keith Packard <keithp@keithp.com>
ao-tools/ao-chaosread/ao-chaosread.c

index ca7b65a7c89074d5e75ac6b11490dacd5fe78f5b..82831201c1b3ffe1e7c1ddf87470f8cb1b6dd80b 100644 (file)
@@ -91,7 +91,6 @@ chaoskey_match(libusb_device *dev, char *match_serial)
        return handle;
 
 out:
-       free(device_serial);
        if (handle)
                libusb_close(handle);
        return 0;