diff options
author | Simon McVittie <simon.mcvittie@collabora.co.uk> | 2011-02-24 17:17:36 +0000 |
---|---|---|
committer | Simon McVittie <simon.mcvittie@collabora.co.uk> | 2011-02-24 17:17:36 +0000 |
commit | d9e1959dcfd643bb7b096eba07e326c1093a2ba3 (patch) | |
tree | ce0cfa6fdf6cfd96cb38fb872bc450a984e3567f /dbus | |
parent | 7f8059e00d61f539ad47844bb80d3c639f6f42c4 (diff) | |
parent | 3681753421e4f5538e938f7d151c901f7c2f34d1 (diff) |
Merge branch 'dbus-1.4'
Diffstat (limited to 'dbus')
-rw-r--r-- | dbus/dbus-sysdeps-unix.c | 49 |
1 files changed, 26 insertions, 23 deletions
diff --git a/dbus/dbus-sysdeps-unix.c b/dbus/dbus-sysdeps-unix.c index fdea6342..9076600a 100644 --- a/dbus/dbus-sysdeps-unix.c +++ b/dbus/dbus-sysdeps-unix.c @@ -3502,29 +3502,6 @@ _dbus_get_standard_session_servicedirs (DBusList **dirs) xdg_data_home = _dbus_getenv ("XDG_DATA_HOME"); xdg_data_dirs = _dbus_getenv ("XDG_DATA_DIRS"); - if (xdg_data_dirs != NULL) - { - if (!_dbus_string_append (&servicedir_path, xdg_data_dirs)) - goto oom; - - if (!_dbus_string_append (&servicedir_path, ":")) - goto oom; - } - else - { - if (!_dbus_string_append (&servicedir_path, "/usr/local/share:/usr/share:")) - goto oom; - } - - /* - * add configured datadir to defaults - * this may be the same as an xdg dir - * however the config parser should take - * care of duplicates - */ - if (!_dbus_string_append (&servicedir_path, DBUS_DATADIR":")) - goto oom; - if (xdg_data_home != NULL) { if (!_dbus_string_append (&servicedir_path, xdg_data_home)) @@ -3546,6 +3523,32 @@ _dbus_get_standard_session_servicedirs (DBusList **dirs) goto oom; } + if (!_dbus_string_append (&servicedir_path, ":")) + goto oom; + + if (xdg_data_dirs != NULL) + { + if (!_dbus_string_append (&servicedir_path, xdg_data_dirs)) + goto oom; + + if (!_dbus_string_append (&servicedir_path, ":")) + goto oom; + } + else + { + if (!_dbus_string_append (&servicedir_path, "/usr/local/share:/usr/share:")) + goto oom; + } + + /* + * add configured datadir to defaults + * this may be the same as an xdg dir + * however the config parser should take + * care of duplicates + */ + if (!_dbus_string_append (&servicedir_path, DBUS_DATADIR)) + goto oom; + if (!_dbus_split_paths_and_append (&servicedir_path, DBUS_UNIX_STANDARD_SESSION_SERVICEDIR, dirs)) |