CID1130007: Resource leak in ogp_spi

Memory leak in ogp_spi_init().

Corresponding to flashrom svn r1774.

Signed-off-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
Acked-by: Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at>
diff --git a/ogp_spi.c b/ogp_spi.c
index f8f7b2d..23431d1 100644
--- a/ogp_spi.c
+++ b/ogp_spi.c
@@ -120,8 +120,10 @@
 		ogp_reg_sck  = OGA1_XP10_CPROM_SCK;
 	} else {
 		msg_perr("Invalid or missing rom= parameter.\n");
+		free(type);
 		return 1;
 	}
+	free(type);
 
 	if (rget_io_perms())
 		return 1;