From: fujiwarat Date: Fri, 27 Apr 2012 02:27:03 +0000 (+0900) Subject: Enable to fall back /etc/machine-id X-Git-Tag: 1.4.99.20121006~48 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=d0df8d3a62fd156029fb1422cd786d3f351b17fe;p=platform%2Fupstream%2Fibus.git Enable to fall back /etc/machine-id http://cgit.freedesktop.org/dbus/dbus/commit/dbus/dbus-sysdeps-unix.c?id=66e52541d5bdd4927a5c702963749760643313f4 BUG=http://code.google.com/p/ibus/issues/detail?id=1389 TEST=Linux desktop Review URL: https://codereview.appspot.com/6111060 --- diff --git a/src/ibusshare.c b/src/ibusshare.c index 95f98d34..ce332ba5 100644 --- a/src/ibusshare.c +++ b/src/ibusshare.c @@ -44,7 +44,11 @@ ibus_get_local_machine_id (void) if (!g_file_get_contents ("/var/lib/dbus/machine-id", &machine_id, NULL, - &error)) { + &error) && + !g_file_get_contents ("/etc/machine-id", + &machine_id, + NULL, + NULL)) { g_warning ("Unable to load /var/lib/dbus/machine-id: %s", error->message); g_error_free (error); machine_id = "machine-id";