Skip to content

Commit

Permalink
use RMW_RET_UNSUPPORTED
Browse files Browse the repository at this point in the history
Signed-off-by: Karsten Knese <karsten@openrobotics.org>
  • Loading branch information
Karsten1987 committed Oct 14, 2019
1 parent 6371fa5 commit 1e8a032
Show file tree
Hide file tree
Showing 6 changed files with 16 additions and 14 deletions.
2 changes: 1 addition & 1 deletion rmw_fastrtps_cpp/src/rmw_publish.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,6 @@ rmw_publish_loaned_message(
(void) allocation;

RMW_SET_ERROR_MSG("rmw_publish_loaned_message not implemented for rmw_fastrtps_cpp");
return RMW_RET_ERROR;
return RMW_RET_UNSUPPORTED;
}
} // extern "C"
7 changes: 4 additions & 3 deletions rmw_fastrtps_cpp/src/rmw_publisher.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -271,7 +271,8 @@ rmw_borrow_loaned_message(
(void) type_support;
(void) ros_message;

return RMW_RET_ERROR;
RMW_SET_ERROR_MSG("rmw_borrow_loaned_message not implemented for rmw_fastrtps_cpp");
return RMW_RET_UNSUPPORTED;
}

rmw_ret_t
Expand All @@ -282,8 +283,8 @@ rmw_return_loaned_message(
(void) publisher;
(void) loaned_message;

RMW_SET_ERROR_MSG("fastrtps currently doesn't support loaned messages");
return RMW_RET_ERROR;
RMW_SET_ERROR_MSG("rmw_return_loaned_message not implemented for rmw_fastrtps_cpp");
return RMW_RET_UNSUPPORTED;
}

rmw_ret_t
Expand Down
6 changes: 3 additions & 3 deletions rmw_fastrtps_cpp/src/rmw_take.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ rmw_take_loaned_message(
(void) allocation;

RMW_SET_ERROR_MSG("rmw_take_loaned_message not implemented for rmw_fastrtps_cpp");
return RMW_RET_ERROR;
return RMW_RET_UNSUPPORTED;
}

rmw_ret_t
Expand All @@ -101,7 +101,7 @@ rmw_take_loaned_message_with_info(
(void) allocation;

RMW_SET_ERROR_MSG("rmw_take_loaned_message_with_info not implemented for rmw_fastrtps_cpp");
return RMW_RET_ERROR;
return RMW_RET_UNSUPPORTED;
}

rmw_ret_t
Expand All @@ -113,7 +113,7 @@ rmw_release_loaned_message(
(void) loaned_message;

RMW_SET_ERROR_MSG("rmw_release_loaned_message_with_info not implemented for rmw_fastrtps_cpp");
return RMW_RET_ERROR;
return RMW_RET_UNSUPPORTED;
}

rmw_ret_t
Expand Down
2 changes: 1 addition & 1 deletion rmw_fastrtps_dynamic_cpp/src/rmw_publish.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ rmw_publish_loaned_message(
(void) allocation;

RMW_SET_ERROR_MSG("rmw_publish_loaned_message is not implemented for rmw_fastrtps_dynamic_cpp");
return RMW_RET_ERROR;
return RMW_RET_UNSUPPORTED;
}

rmw_ret_t
Expand Down
7 changes: 4 additions & 3 deletions rmw_fastrtps_dynamic_cpp/src/rmw_publisher.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -267,7 +267,8 @@ rmw_borrow_loaned_message(
(void) type_support;
(void) ros_message;

return RMW_RET_ERROR;
RMW_SET_ERROR_MSG("rmw_borrow_loaned_message is not implemented for rmw_fastrtps_dynamic_cpp");
return RMW_RET_UNSUPPORTED;
}

rmw_ret_t
Expand All @@ -278,8 +279,8 @@ rmw_return_loaned_message(
(void) publisher;
(void) loaned_message;

RMW_SET_ERROR_MSG("fastrtps-dynamic currently doesn't support loaned messages");
return RMW_RET_ERROR;
RMW_SET_ERROR_MSG("rmw_return_loaned_message is not implemented for rmw_fastrtps_dynamic_cpp");
return RMW_RET_UNSUPPORTED;
}

rmw_ret_t
Expand Down
6 changes: 3 additions & 3 deletions rmw_fastrtps_dynamic_cpp/src/rmw_take.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ rmw_take_loaned_message(
(void) allocation;

RMW_SET_ERROR_MSG("rmw_take_loaned_message is not implemented for rmw_fastrtps_dynamic_cpp");
return RMW_RET_ERROR;
return RMW_RET_UNSUPPORTED;
}

rmw_ret_t
Expand All @@ -102,7 +102,7 @@ rmw_take_loaned_message_with_info(

RMW_SET_ERROR_MSG(
"rmw_take_loaned_message_with_info is not implemented for rmw_fastrtps_dynamic_cpp");
return RMW_RET_ERROR;
return RMW_RET_UNSUPPORTED;
}

rmw_ret_t
Expand All @@ -114,7 +114,7 @@ rmw_release_loaned_message(
(void) loaned_message;

RMW_SET_ERROR_MSG("rmw_release_loaned_message is not implemented for rmw_fastrtps_dynamic_cpp");
return RMW_RET_ERROR;
return RMW_RET_UNSUPPORTED;
}

rmw_ret_t
Expand Down

0 comments on commit 1e8a032

Please sign in to comment.