diff options
author | Ralf Habacker <ralf.habacker@freenet.de> | 2010-03-20 21:11:10 +0100 |
---|---|---|
committer | unknown <Administrator@.(none)> | 2010-03-20 21:53:57 +0100 |
commit | 235e8dfe2e1b741bbe117825f6d3fc26fc94ca6f (patch) | |
tree | 13efa22140bbeabac0ce51cf267f2e883487c6ab /bus/config-loader-expat.c | |
parent | f76399115ec64a612b6f8cf489db74b32523d765 (diff) | |
download | dbus-235e8dfe2e1b741bbe117825f6d3fc26fc94ca6f.tar.gz |
Fixed gcc on windows limitation
A pointer to a function or variable marked as dllimport
cannot be used as a constant address.
Diffstat (limited to 'bus/config-loader-expat.c')
-rw-r--r-- | bus/config-loader-expat.c | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/bus/config-loader-expat.c b/bus/config-loader-expat.c index 51bbb51b..b571fda3 100644 --- a/bus/config-loader-expat.c +++ b/bus/config-loader-expat.c @@ -26,12 +26,7 @@ #include <dbus/dbus-internals.h> #include <expat.h> -static XML_Memory_Handling_Suite memsuite = -{ - dbus_malloc, - dbus_realloc, - dbus_free -}; +static XML_Memory_Handling_Suite memsuite; typedef struct { @@ -196,7 +191,11 @@ bus_config_load (const DBusString *file, _dbus_string_free (&context.content); return NULL; } - + + memsuite.malloc_fcn = dbus_malloc; + memsuite.realloc_fcn = dbus_realloc; + memsuite.free_fcn = dbus_free; + expat = XML_ParserCreate_MM ("UTF-8", &memsuite, NULL); if (expat == NULL) { |