[PATCH v2 11/12] os: Fix a memory leak

Pauli ext-pauli.nieminen at nokia.com
Thu Dec 30 09:19:42 PST 2010


From: Pauli Nieminen <ext-pauli.nieminen at nokia.com>

Signed-off-by: Pauli Nieminen <ext-pauli.nieminen at nokia.com>
Reviewed-by: Alan Coopersmith <alan.coopersmith at oracle.com>
---
 os/access.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/os/access.c b/os/access.c
index d43fdf8..494986e 100644
--- a/os/access.c
+++ b/os/access.c
@@ -1057,8 +1057,10 @@ Bool LocalClient(ClientPtr client)
 	}
 	for (host = selfhosts; host; host = host->next)
 	{
-	    if (addrEqual (family, addr, alen, host))
+	    if (addrEqual (family, addr, alen, host)) {
+		free(from);
 		return TRUE;
+	    }
 	}
 	free(from);
     }
-- 
1.7.0.4



More information about the xorg-devel mailing list