/pidgin/main: 4f72b9501fb2: util.c: Fix win32-only leak in silcp...

Niels Thykier niels at thykier.net
Sun Jan 27 05:57:49 EST 2013


Changeset: 4f72b9501fb2a8070945c8f1259c7e9b2f3858a1
Author:	 Niels Thykier <niels at thykier.net>
Date:	 2013-01-26 03:43 -0500
Branch:	 default
URL: http://hg.pidgin.im/pidgin/main/rev/4f72b9501fb2

Description:

util.c: Fix win32-only leak in silcpurple_check_silc_dir

Refs #15472.

diffstat:

 libpurple/protocols/silc/util.c |  7 +++++++
 1 files changed, 7 insertions(+), 0 deletions(-)

diffs (17 lines):

diff --git a/libpurple/protocols/silc/util.c b/libpurple/protocols/silc/util.c
--- a/libpurple/protocols/silc/util.c
+++ b/libpurple/protocols/silc/util.c
@@ -309,6 +309,13 @@ gboolean silcpurple_check_silc_dir(Purpl
 	if (fd != -1)
 		close(fd);
 
+#ifdef _WIN32
+	/* on win32, we calloc pw so pass it to free
+	 * (see the getpwuid code below)
+	 */
+	free(pw);
+#endif
+
 	return TRUE;
 }
 



More information about the Commits mailing list