From 7e00765bdbb9e3ad9fcc43376ef73eebb537a348 Mon Sep 17 00:00:00 2001 From: Michel Hidalgo Date: Tue, 7 Jul 2020 10:48:07 -0300 Subject: [PATCH] Require enclave upon rmw_init() call. (#247) Signed-off-by: Michel Hidalgo --- rmw/include/rmw/init.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/rmw/include/rmw/init.h b/rmw/include/rmw/init.h index 4ff20b20..85d7aad8 100644 --- a/rmw/include/rmw/init.h +++ b/rmw/include/rmw/init.h @@ -60,12 +60,15 @@ rmw_get_zero_initialized_context(void); * guard conditions, and is also required to properly call `rmw_shutdown()`. * * \pre The given options must have been initialized - * i.e. `rmw_init_options_init()` called on it. + * i.e. `rmw_init_options_init()` called on it and + * an enclave set. * \pre The given context must be zero initialized. * * \post If initialization fails, context will remain zero initialized. * * \remarks If options are zero-initialized, then `RMW_RET_INVALID_ARGUMENT` is returned. + * If options are initialized but no enclave is provided, then `RMW_RET_INVALID_ARGUMENT` + * is returned. * If context has been already initialized (`rmw_init()` was called on it), then * `RMW_RET_INVALID_ARGUMENT` is returned. *