summaryrefslogtreecommitdiffstats
path: root/devel/gnome-vfs/files/patch-libgnomevfs_xdgmime.c
diff options
context:
space:
mode:
authormarcus <marcus@df743ca5-7f9a-e211-a948-0013205c9059>2004-01-13 14:22:58 +0800
committermarcus <marcus@df743ca5-7f9a-e211-a948-0013205c9059>2004-01-13 14:22:58 +0800
commit9c2092d12f5f1f8a0a7853e523c742819126e462 (patch)
treed5dac2ac29871e0c809b064b8cfd6a0bd51eb3d4 /devel/gnome-vfs/files/patch-libgnomevfs_xdgmime.c
parent5e12f2c746b9b6f37e7dcbdb4b91e5e3e5be968f (diff)
downloadmarcuscom-ports-9c2092d12f5f1f8a0a7853e523c742819126e462.tar
marcuscom-ports-9c2092d12f5f1f8a0a7853e523c742819126e462.tar.gz
marcuscom-ports-9c2092d12f5f1f8a0a7853e523c742819126e462.tar.bz2
marcuscom-ports-9c2092d12f5f1f8a0a7853e523c742819126e462.tar.lz
marcuscom-ports-9c2092d12f5f1f8a0a7853e523c742819126e462.tar.xz
marcuscom-ports-9c2092d12f5f1f8a0a7853e523c742819126e462.tar.zst
marcuscom-ports-9c2092d12f5f1f8a0a7853e523c742819126e462.zip
Correct a memory glitch that broke MIME info (most noticeably to me in yelp).
git-svn-id: svn://creme-brulee.marcuscom.com/ports/trunk@1639 df743ca5-7f9a-e211-a948-0013205c9059
Diffstat (limited to 'devel/gnome-vfs/files/patch-libgnomevfs_xdgmime.c')
-rw-r--r--devel/gnome-vfs/files/patch-libgnomevfs_xdgmime.c21
1 files changed, 21 insertions, 0 deletions
diff --git a/devel/gnome-vfs/files/patch-libgnomevfs_xdgmime.c b/devel/gnome-vfs/files/patch-libgnomevfs_xdgmime.c
new file mode 100644
index 000000000..1bf100bf0
--- /dev/null
+++ b/devel/gnome-vfs/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);