diff src/bar_info.c @ 700:b2eb4ff74d13

Use g_build_filename() to build paths.
author zas_
date Tue, 20 May 2008 21:51:25 +0000
parents 8268cbe682f1
children e6ebae313d46
line wrap: on
line diff
--- a/src/bar_info.c	Tue May 20 20:11:29 2008 +0000
+++ b/src/bar_info.c	Tue May 20 21:51:25 2008 +0000
@@ -101,8 +101,10 @@
 		comment_dir = cache_get_location(CACHE_TYPE_METADATA, fd->path, FALSE, &mode);
 		if (cache_ensure_dir_exists(comment_dir, mode))
 			{
-			comment_path = g_strconcat(comment_dir, "/", fd->name,
-						   GQ_CACHE_EXT_METADATA, NULL);
+			gchar *filename = g_strconcat(fd->name, GQ_CACHE_EXT_METADATA, NULL);
+			
+			comment_path = g_build_filename(comment_dir, filename, NULL);
+			g_free(filename);
 			}
 		g_free(comment_dir);
 		}