summaryrefslogtreecommitdiffstats
path: root/src/responder/ifp
diff options
context:
space:
mode:
authorJakub Hrozek <jhrozek@redhat.com>2014-06-24 14:28:51 +0200
committerJakub Hrozek <jhrozek@redhat.com>2014-07-08 20:35:11 +0200
commit0c1d65998907930678da2d091789446f2c344d5d (patch)
treec0b95ab34b61d48f4644b7bde3cb2a8266958c7c /src/responder/ifp
parent1f2507e1fd089f2bf3458cfb4faeaa9669d72f98 (diff)
downloadsssd-0c1d65998907930678da2d091789446f2c344d5d.tar.gz
sssd-0c1d65998907930678da2d091789446f2c344d5d.tar.xz
sssd-0c1d65998907930678da2d091789446f2c344d5d.zip
IFP: Return a specific value on failure connecting to the system bus
We need to treat the failure to connect to the system bus as non-fatal. In this commit, we introduce a special error code and only print a DEBUG message when this error code is returned from the startup function. Reviewed-by: Pavel Březina <pbrezina@redhat.com>
Diffstat (limited to 'src/responder/ifp')
-rw-r--r--src/responder/ifp/ifpsrv.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/responder/ifp/ifpsrv.c b/src/responder/ifp/ifpsrv.c
index 5dc5652b6..9014c3e85 100644
--- a/src/responder/ifp/ifpsrv.c
+++ b/src/responder/ifp/ifpsrv.c
@@ -192,7 +192,7 @@ sysbus_init(TALLOC_CTX *mem_ctx,
DEBUG(SSSDBG_CRIT_FAILURE,
"Failed to connect to D-BUS system bus: [%s]\n",
dbus_error.message);
- ret = EIO;
+ ret = ERR_NO_SYSBUS;
goto fail;
}
dbus_connection_set_exit_on_disconnect(conn, FALSE);
@@ -372,7 +372,11 @@ int ifp_process_init(TALLOC_CTX *mem_ctx,
INFOPIPE_IFACE,
ifp_ifaces,
ifp_ctx, &ifp_ctx->sysbus);
- if (ret != EOK) {
+ if (ret == ERR_NO_SYSBUS) {
+ DEBUG(SSSDBG_MINOR_FAILURE,
+ "The system bus is not available..\n");
+ /* Explicitly ignore, the D-Bus daemon will start us */
+ } else if (ret != EOK) {
DEBUG(SSSDBG_CRIT_FAILURE,
"Failed to connect to the system message bus\n");
talloc_free(ifp_ctx);