Use RMW_RET_NODE_NAME_NON_EXISTENT only if defined
Signed-off-by: Erik Boasson <eb@ilities.com>
This commit is contained in:
parent
c2c69ac032
commit
a55c9cb605
1 changed files with 7 additions and 2 deletions
|
@ -2442,9 +2442,14 @@ static rmw_ret_t get_node_guids(
|
|||
if (ret != RMW_RET_OK) {
|
||||
return ret;
|
||||
} else if (guids.size() == 0) {
|
||||
/* It appears the get_..._by_node operations are supposed to return NODE_NAME_NON_EXISTENT
|
||||
if no such node exists */
|
||||
/* It appears the get_..._by_node operations are supposed to return
|
||||
NODE_NAME_NON_EXISTENT (newly introduced in Eloquent) or ERROR
|
||||
(on Dashing and earlier) if no such node exists */
|
||||
#ifdef RMW_RET_NODE_NAME_NON_EXISTENT
|
||||
return RMW_RET_NODE_NAME_NON_EXISTENT;
|
||||
#else
|
||||
return RMW_RET_ERROR;
|
||||
#endif
|
||||
} else {
|
||||
return RMW_RET_OK;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue