Просмотр исходного кода

Merge trunk revision 2403:
r2403 | chrissie | 2009-09-07 00:28:25 -0700 (Mon, 07 Sep 2009) | 2 lines

Return CS_ERR_NOT_EXIST if a client tries to contact a plugin that isn't loaded.



git-svn-id: http://svn.fedorahosted.org/svn/corosync/branches/flatiron@2452 fd59a12c-fef9-0310-b244-a6a79926bd2f

Steven Dake 16 лет назад
Родитель
Сommit
af1fd25c4c
1 измененных файлов с 2 добавлено и 1 удалено
  1. 2 1
      exec/coroipcs.c

+ 2 - 1
exec/coroipcs.c

@@ -1385,7 +1385,6 @@ int coroipcs_handler_dispatch (
 		if (res != 1) {
 			return (0);
 		}
-		req_setup_send (conn_info, CS_OK);
 
 		pthread_mutex_init (&conn_info->mutex, NULL);
 		req_setup = (mar_req_setup_t *)conn_info->setup_msg;
@@ -1393,9 +1392,11 @@ int coroipcs_handler_dispatch (
 		 * Is the service registered ?
 		 */
 		if (api->service_available (req_setup->service) == 0) {
+			req_setup_send (conn_info, CS_ERR_NOT_EXIST);
 			ipc_disconnect (conn_info);
 			return (0);
 		}
+		req_setup_send (conn_info, CS_OK);
 
 #if _POSIX_THREAD_PROCESS_SHARED < 1
 		conn_info->semkey = req_setup->semkey;