summaryrefslogtreecommitdiffstats
path: root/devel/gnomevfs2/files/patch-libgnomevfs_xdgmime.c
diff options
context:
space:
mode:
Diffstat (limited to 'devel/gnomevfs2/files/patch-libgnomevfs_xdgmime.c')
-rw-r--r--devel/gnomevfs2/files/patch-libgnomevfs_xdgmime.c21
1 files changed, 21 insertions, 0 deletions
diff --git a/devel/gnomevfs2/files/patch-libgnomevfs_xdgmime.c b/devel/gnomevfs2/files/patch-libgnomevfs_xdgmime.c
new file mode 100644
index 000000000..1bf100bf0
--- /dev/null
+++ b/devel/gnomevfs2/files/patch-libgnomevfs_xdgmime.c
@@ -0,0 +1,21 @@
+--- libgnomevfs/xdgmime.c.orig Tue Jan 13 01:20:05 2004
++++ libgnomevfs/xdgmime.c Tue Jan 13 01:20:35 2004
+@@ -97,7 +97,7 @@
+
+ xdg_data_dirs = getenv ("XDG_DATA_DIRS");
+ if (xdg_data_dirs == NULL)
+- xdg_data_dirs = "/usr/local/share/:/usr/share/";
++ xdg_data_dirs = "%%LOCALBASE%%/share/:/usr/share/";
+
+ ptr = xdg_data_dirs;
+
+@@ -121,7 +121,8 @@
+ len = end_ptr - ptr;
+ else
+ len = end_ptr - ptr + 1;
+- dir = malloc (len);
++ dir = malloc (len + 1);
++ memset (dir, 0, len + 1);
+ strncpy (dir, ptr, len);
+ _xdg_mime_init_from_directory (dir);
+ free (dir);