[geany/geany-plugins] 3388d8: treebrowser: Fix a potential invalid free
Colomban Wendling
git-noreply at xxxxx
Wed Jun 20 20:53:55 UTC 2012
Branch: refs/heads/master
Author: Colomban Wendling <ban at herbesfolles.org>
Committer: Colomban Wendling <ban at herbesfolles.org>
Date: Wed, 20 Jun 2012 20:53:55
Commit: 3388d87c421d25bca4fd3c202813291dfdb6ef98
https://github.com/geany/geany-plugins/commit/3388d87c421d25bca4fd3c202813291dfdb6ef98
Log Message:
-----------
treebrowser: Fix a potential invalid free
Modified Paths:
--------------
treebrowser/src/treebrowser.c
Modified: treebrowser/src/treebrowser.c
4 files changed, 2 insertions(+), 2 deletions(-)
===================================================================
@@ -791,7 +791,7 @@ enum
{
int i = 0;
gboolean founded = FALSE, global_founded = FALSE;
- gchar *new = "";
+ gchar *new = NULL;
gchar **root_segments = NULL, **find_segments = NULL;
guint root_segments_n = 0, find_segments_n = 0;
@@ -804,7 +804,7 @@ enum
for (i = 1; i<=find_segments_n; i++)
{
- new = g_strconcat(new, G_DIR_SEPARATOR_S, find_segments[i], NULL);
+ new = g_strconcat(new ? new : "", G_DIR_SEPARATOR_S, find_segments[i], NULL);
if (founded)
{
@@ Diff output truncated at 100000 characters. @@
--------------
This E-Mail was brought to you by github_commit_mail.py (Source: TBD).
More information about the Plugins-Commits
mailing list