-
Notifications
You must be signed in to change notification settings - Fork 684
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix(autoware_pointcloud_preprocessor): fix potential double unlock in concatenate node #10082
base: main
Are you sure you want to change the base?
fix(autoware_pointcloud_preprocessor): fix potential double unlock in concatenate node #10082
Conversation
Thank you for contributing to the Autoware project! 🚧 If your pull request is in progress, switch it to draft mode. Please ensure:
|
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #10082 +/- ##
==========================================
- Coverage 26.77% 26.76% -0.02%
==========================================
Files 1397 1397
Lines 107977 107994 +17
Branches 41580 41577 -3
==========================================
- Hits 28908 28901 -7
- Misses 76194 76223 +29
+ Partials 2875 2870 -5
*This pull request uses carry forward flags. Click here to find out more. ☔ View full report in Codecov by Sentry. |
@vividf |
As remarked by @knzo25 offline some days ago, and as per the discussion @drwnz @vividf @manato and I just had,. it might be better to remove all locking completely as the callbacks within one node will always be in a mutually exclusive callback group by default, even when using a multithreaded executor. |
@mojomex |
Signed-off-by: vividf <yihsiang.fang@tier4.jp>
Signed-off-by: vividf <yihsiang.fang@tier4.jp>
d8c5033
to
e272e0b
Compare
Signed-off-by: vividf <yihsiang.fang@tier4.jp>
Signed-off-by: vividf <yihsiang.fang@tier4.jp>
...ing/autoware_pointcloud_preprocessor/src/concatenate_data/concatenate_and_time_sync_node.cpp
Outdated
Show resolved
Hide resolved
...ing/autoware_pointcloud_preprocessor/src/concatenate_data/concatenate_and_time_sync_node.cpp
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
There's two small aesthetic suggestions I left but the algorithm itself loogs good and works fine 👍
Signed-off-by: vividf <yihsiang.fang@tier4.jp>
Description
This PR resolves a potential double unlock issue in the concatenate node. Previously, under certain conditions, the mutex could be unlocked twice, leading to undefined behavior and potential segmentation faults.
Related links
Note: This PR needs to rebase after #10074 is merged.
Parent Issue:
How was this PR tested?
Notes for reviewers
None.
Interface changes
None.
Effects on system behavior
None.