summaryrefslogtreecommitdiff
path: root/gdk-pixbuf/queryloaders.c
diff options
context:
space:
mode:
authorTor Lillqvist <tml@iki.fi>2004-03-15 13:07:04 +0000
committerTor Lillqvist <tml@src.gnome.org>2004-03-15 13:07:04 +0000
commitba7a95175bc33b37642a198dd6d7642c331f9002 (patch)
tree629fbfcb889249b3c3538391394664b1c3cb4e22 /gdk-pixbuf/queryloaders.c
parentde2332ee9afc4b2abc278497021923206b74bd74 (diff)
downloadgtk+-ba7a95175bc33b37642a198dd6d7642c331f9002.tar.gz
Merges from stable branch that had been left out. (#136282, J. Ali Harlow)
2004-03-15 Tor Lillqvist <tml@iki.fi> Merges from stable branch that had been left out. (#136282, J. Ali Harlow) Changes for run-time lookup of installation location on Win32: * Makefile.am (INCLUDES): Define GTK_PREFIX as $(prefix). * gdk-pixbuf-io.c (get_sysconfdir): New function, look up installation location at runtime and deduce GTK_SYSCONFDIR from it. (get_toplevel): Similar, for the top-level installation directory. (correct_prefix): Replace compile-time prefix with run-time prefix. (get_libdir): Remove, not used any longer. (gdk_pixbuf_io_init): Call correct_prefix() on Win32. * queryloaders.c (query_module): [Win32] Change backslahses into slashes in path.
Diffstat (limited to 'gdk-pixbuf/queryloaders.c')
-rw-r--r--gdk-pixbuf/queryloaders.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/gdk-pixbuf/queryloaders.c b/gdk-pixbuf/queryloaders.c
index f5428f30da..e2f6bfc910 100644
--- a/gdk-pixbuf/queryloaders.c
+++ b/gdk-pixbuf/queryloaders.c
@@ -162,6 +162,19 @@ query_module (const char *dir, const char *file)
GdkPixbufFormat *info;
GdkPixbufModule *vtable;
+#ifdef G_OS_WIN32
+ /* Replace backslashes in path with forward slashes, so that
+ * it reads in without problems.
+ */
+ {
+ char *p = path;
+ while (*p) {
+ if (*p == '\\')
+ *p = '/';
+ p++;
+ }
+ }
+#endif
info = g_new0 (GdkPixbufFormat, 1);
vtable = g_new0 (GdkPixbufModule, 1);