Function rmw_init_options_fini

Function Documentation

rmw_ret_t rmw_init_options_fini(rmw_init_options_t *init_options)

Finalize the given init options.

This function will return early if a logical error, such as RMW_RET_INVALID_ARGUMENT or RMW_RET_INCORRECT_RMW_IMPLEMENTATION, ensues, leaving the given init options unchanged. Otherwise, it will proceed despite errors, freeing as much resources as it can and zero initializing the given init options.

Attribute

Adherence

Allocates Memory

Yes

Thread-Safe

No

Uses Atomics

Yes

Lock-Free

Yes

Remark

If init options are zero initialized, then RMW_RET_INVALID_ARGUMENT is returned.

This should be defined by the rmw implementation.

Pre:

The given init options must have been initialized i.e. had rmw_init_options_init() called on.

Parameters:

init_options[inout] object to finalized

Returns:

RMW_RET_OK if finalization is successful, or

Returns:

RMW_RET_INVALID_ARGUMENT if any arguments are invalid, or

Returns:

RMW_RET_INCORRECT_RMW_IMPLEMENTATION if the implementation identifier does not match the implementation of this function, or

Returns:

RMW_RET_ERROR if an unspecified error occurs.