[geany/geany-plugins] 495712: Geanyvc: fix leak

Pavel Roschin git-noreply at xxxxx
Thu Nov 28 21:36:19 UTC 2013


Branch:      refs/heads/master
Author:      Pavel Roschin <roshin at scriptumplus.ru>
Committer:   Frank Lanitz <frank at frank.uvena.de>
Date:        Thu, 28 Nov 2013 21:36:19 UTC
Commit:      4957126bc954f3e13969ee169876a1b1b9d04818
             https://github.com/geany/geany-plugins/commit/4957126bc954f3e13969ee169876a1b1b9d04818

Log Message:
-----------
Geanyvc: fix leak


Modified Paths:
--------------
    geanyvc/src/externdiff.c

Modified: geanyvc/src/externdiff.c
4 files changed, 3 insertions(+), 1 deletions(-)
===================================================================
@@ -50,8 +50,10 @@ enum
 
 	for (i = 0; i < EXTERNAL_DIFF_COUNT; i++)
 	{
-		if (g_find_program_in_path(viewers[i]))
+		gchar *path = g_find_program_in_path(viewers[i]);
+		if (path)
 		{
+			g_free(path);
 			extern_diff_viewer = (gchar *) viewers[i];
 			return viewers[i];
 		}



--------------
This E-Mail was brought to you by github_commit_mail.py (Source: https://github.com/geany/infrastructure).


More information about the Plugins-Commits mailing list