Skip to content

Commit

Permalink
swap comparison sides
Browse files Browse the repository at this point in the history
  • Loading branch information
dirk-thomas authored Aug 27, 2018
1 parent c71584d commit a1cae4a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions rcl/src/rcl/wait.c
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ __wait_set_clean_up(rcl_wait_set_t * wait_set, rcl_allocator_t allocator)
if (wait_set->subscriptions) {
rcl_ret_t ret = rcl_wait_set_resize(wait_set, 0, 0, 0, 0, 0);
(void)ret; // NO LINT
assert(ret == RCL_RET_OK); // Defensive, shouldn't fail with size 0.
assert(RCL_RET_OK == ret); // Defensive, shouldn't fail with size 0.
}
if (wait_set->impl) {
allocator.deallocate(wait_set->impl, allocator.state);
Expand Down Expand Up @@ -575,7 +575,7 @@ rcl_wait(rcl_wait_set_t * wait_set, int64_t timeout)
}
}

if (ret == RMW_RET_TIMEOUT && !is_timer_timeout) {
if (RMW_RET_TIMEOUT == ret && !is_timer_timeout) {
return RCL_RET_TIMEOUT;
}
return RCL_RET_OK;
Expand Down

0 comments on commit a1cae4a

Please sign in to comment.