From 9a3ccc6059672e90cdecc0ad8afd1127af249c3b Mon Sep 17 00:00:00 2001 From: Christine Caulfield Date: Fri, 20 Feb 2009 08:24:40 +0000 Subject: [PATCH] Don't crash if a library tries to talk to a module that is not loaded git-svn-id: http://svn.fedorahosted.org/svn/corosync/trunk@1772 fd59a12c-fef9-0310-b244-a6a79926bd2f --- exec/ipc.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/exec/ipc.c b/exec/ipc.c index 5c096c87..552f0c25 100644 --- a/exec/ipc.c +++ b/exec/ipc.c @@ -448,6 +448,13 @@ static int poll_handler_connection ( } /* + * Is the service registered ? + */ + if (!ais_service[conn_info->service]) { + return poll_handler_connection_destroy (conn_info); + } + + /* * Read the header and process it */ if (conn_info->service == SOCKET_SERVICE_INIT && (revent & POLLIN)) {