summaryrefslogtreecommitdiff
path: root/android/ipc.c
diff options
context:
space:
mode:
authorSzymon Janc <szymon.janc@tieto.com>2013-12-03 13:42:08 +0100
committerLuiz Augusto von Dentz <luiz.von.dentz@intel.com>2013-12-09 11:34:10 +0200
commit17c9c2073a4e07ad26f1c62868805bc8bca494cb (patch)
tree81a1cf463c28c93ec13b33c8dab7030182bf2cec /android/ipc.c
parent7567b13ef328b74794d00bfec2a3a7f51231be6e (diff)
downloadbluez-17c9c2073a4e07ad26f1c62868805bc8bca494cb.tar.gz
android: Fix missing failure check in ipc_init
If connecting command socket failed daemon should be terminated.
Diffstat (limited to 'android/ipc.c')
-rw-r--r--android/ipc.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/android/ipc.c b/android/ipc.c
index 1d369a834..6f940cdb1 100644
--- a/android/ipc.c
+++ b/android/ipc.c
@@ -229,6 +229,8 @@ static gboolean cmd_connect_cb(GIOChannel *io, GIOCondition cond,
void ipc_init(void)
{
cmd_io = connect_hal(cmd_connect_cb);
+ if (!cmd_io)
+ raise(SIGTERM);
}
void ipc_cleanup(void)