From 0a1d7c1844dc6104eefe43b38400f3d94868428b Mon Sep 17 00:00:00 2001 From: Lars Uebernickel Date: Wed, 5 Dec 2012 10:37:16 +0000 Subject: Don't shorten the app id to seven characters --- src/im-application-list.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'src/im-application-list.c') diff --git a/src/im-application-list.c b/src/im-application-list.c index 607b0fc..5a7f768 100644 --- a/src/im-application-list.c +++ b/src/im-application-list.c @@ -411,8 +411,13 @@ im_application_list_canonical_id (const gchar *id) { gchar *str; gchar *p; + int len; - str = g_strndup (id, strlen (id) - g_str_has_suffix (id, ".desktop") ? 7 : 0); + len = strlen (id); + if (g_str_has_suffix (id, ".desktop")) + len -= 8; + + str = g_strndup (id, len); for (p = str; *p; p++) { -- cgit v1.2.3