diff --git a/pony_spi.c b/pony_spi.c index 6005bd4c2..86ef238cf 100644 --- a/pony_spi.c +++ b/pony_spi.c @@ -145,6 +145,7 @@ static int pony_spi_init(void) sp_fd = sp_openserport(arg, 9600); if (sp_fd == SER_INV_FD) { free(arg); + free(data); return 1; } if (register_shutdown(pony_spi_shutdown, data) != 0) {