-
Notifications
You must be signed in to change notification settings - Fork 824
Fix asan and undefined behavior error [10916] #1845
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
Conversation
Signed-off-by: Zijian Wang <[email protected]>
Hi @MiguelCompany , thanks for reviewing in an previous version of this PR: #1834. I opened this new PR since I messed up with DCO signoff in the previous one. I applied your suggestion and verified that the new change will pass both Address and UndefinedBehavior sanitizer now :D Please let me what else is needed to merge this PR. Thank you! |
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
Hi @MiguelCompany , thanks for approving. I see that some CI tests are failing. Are these legitimate concerns and actually caused by my PR? |
I have to check, but there are two tests that are failing on all platforms: |
@richiprosima Please test this |
The code to generate the default DataSharing domain ID has been extracted to a common place to avoid code duplication and maintenance. Signed-off-by: Iker Luengo <[email protected]>
The piece of code making the bit shifting was used in several places, but only some of them were modified on this PR, breaking the logic and making the tests fail. Commit cf8c162 centralizes this code in a single place and solved the testing errors. |
Signed-off-by: Iker Luengo <[email protected]>
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 with green CI.
Thank you @princeward and @IkerLuengo |
This is a port of #1845 from <master> to <2.2.x> * Fix asan and undefined behavior error, take 2 Signed-off-by: Zijian Wang <[email protected]> * Centralise the generation of the default DataSharing domain ID The code to generate the default DataSharing domain ID has been extracted to a common place to avoid code duplication and maintenance. Signed-off-by: Iker Luengo <[email protected]> * Resolve test linker errors Signed-off-by: Iker Luengo <[email protected]> Co-authored-by: Iker Luengo <[email protected]> Signed-off-by: Iker Luengo <[email protected]>
This is a port of #1845 from <master> to <2.2.x> * Fix asan and undefined behavior error, take 2 Signed-off-by: Zijian Wang <[email protected]> * Centralise the generation of the default DataSharing domain ID The code to generate the default DataSharing domain ID has been extracted to a common place to avoid code duplication and maintenance. Signed-off-by: Iker Luengo <[email protected]> * Resolve test linker errors Signed-off-by: Iker Luengo <[email protected]> Co-authored-by: Iker Luengo <[email protected]> Signed-off-by: Iker Luengo <[email protected]>
Fix two error reported by AddressSanitizer and UndefinedBehaviorSanitizer.
The AddressSanitizer error is trivial.
For the UndefinedBehaviorSanitizer error, left shifting a uint64 by 64 bits is considered undefined behavior. See this article for reference.
This is take 2 of an earlier PR: #1834