[Xfce4-commits] <xfce4-taskmanager:master> Fix g_snprintf call for task name

Mike Massonnet noreply at xfce.org
Thu Jun 3 23:56:01 CEST 2010


Updating branch refs/heads/master
         to bb4c139c7365301e60dc44c9e004cf8350c88b22 (commit)
       from 7b60724473e1e77456cf2282ebf14e98fd66acd1 (commit)

commit bb4c139c7365301e60dc44c9e004cf8350c88b22
Author: Mike Massonnet <mmassonnet at xfce.org>
Date:   Thu Jun 3 23:46:55 2010 +0200

    Fix g_snprintf call for task name
    
    Don't pass task name as format, instead call g_snprintf safely with "%s"
    and pass the task name as an argument.

 src/task-manager.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/src/task-manager.c b/src/task-manager.c
index 67473dc..cba8a73 100644
--- a/src/task-manager.c
+++ b/src/task-manager.c
@@ -127,7 +127,7 @@ pretty_cmdline (gchar *cmdline, gchar *comm)
 			gchar *p = g_strstr_len (text, -1, comm);
 			if (p != NULL)
 			{
-				g_snprintf (text, g_utf8_strlen (text, -1), p);
+				g_snprintf (text, g_utf8_strlen (text, -1), "%s", p);
 			}
 		}
 	}



More information about the Xfce4-commits mailing list