Skip to content

Commit

Permalink
Fix potential memory leak when canceling responsed failed
Browse files Browse the repository at this point in the history
This patch fixed a potential memeory leak when calling to cancel
response failed.

Fix: #983
  • Loading branch information
minggangw committed Aug 8, 2024
1 parent 7b9febf commit 742e7d0
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/rcl_action_bindings.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -655,6 +655,7 @@ NAN_METHOD(ActionProcessCancelRequest) {
rcl_get_error_string().str);
rcl_reset_error();
}
free(cancel_response_ptr);
Nan::ThrowError(cancel_error.str);
info.GetReturnValue().Set(Nan::Undefined());
return;
Expand Down

0 comments on commit 742e7d0

Please sign in to comment.