From 4b47b4a9cdce3bd0368aacb8164aa02e05670a88 Mon Sep 17 00:00:00 2001
From: Peter Hutterer <peter.hutterer@who-t.net>
Date: Tue, 19 Jul 2011 11:42:12 +1000
Subject: Don't free anything on PreInit failure, let UnInit take care of it

Avoid double free's by the server when it calls UnInit.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>

diff --git a/src/xf86Fpit.c b/src/xf86Fpit.c
index 78b44a2..2da34aa 100644
--- src/xf86Fpit.c
+++ src/xf86Fpit.c
@@ -567,12 +567,6 @@ static int xf86FpitInit(InputDriverPtr drv, InputInfoPtr pInfo, int flags)
 	str = xf86FindOptionValue(pInfo->options, "Device");
 	if (!str) {
 		xf86Msg(X_ERROR, "%s: No Device specified in FPIT module config.\n", pInfo->name);
-		if (priv) {
-			if (priv->fpitDev) {
-				free(priv->fpitDev);
-			}
-			free(priv);
-		}
 		return BadValue;
 	}
 	priv->fpitDev = strdup(str);
-- 
cgit v0.10.2

