Fix CodeQL findings: 8-0-1, 0-1-2, 18-4-1, 6-8-4#550
Open
castler wants to merge 4 commits into
Open
Conversation
Add parentheses to make operator precedence explicit in expressions where higher-precedence operators (+, -, *, ==, !=, >) are used as sub-expressions of lower-precedence operators (&&, ||, ?, <=, <, >). This resolves all 32 CodeQL RULE-8-0-1 findings. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…0-1-2) Wrap all unused non-void function return values with std::ignore to satisfy MISRA RULE-0-1-2. Affected calls include close(), pipe(), read(), write(), memset(), memcpy(), emplace_back(), emplace(), erase(), for_each(), and project-specific functions. This resolves all 34 CodeQL RULE-0-1-2 findings. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Mark defaulted move constructors and move assignment operators as noexcept in configuration headers, instance_identifier.h, proxy_method_base.h, and tracing_runtime.h. This resolves all 13 CodeQL RULE-18-4-1 findings. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…6-8-4) Add lvalue ref-qualifiers (&) to member functions that return references or pointers to their object or subobjects, preventing calls on temporaries that would produce dangling references. Updated declarations, definitions, base classes, overrides, and mocks consistently across the codebase. This resolves all 50 CodeQL RULE-6-8-4 findings. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
castler
commented
Jun 16, 2026
| { | ||
| auto& method = method_key_value_pair.second.get(); | ||
| method.InitializeInArgsAndReturnValues(); | ||
| std::ignore = method.InitializeInArgsAndReturnValues(); |
Contributor
Author
There was a problem hiding this comment.
This is weired, and should most certainly be handled
castler
commented
Jun 16, 2026
| ++current_timestamp_; | ||
| event_data_control_composite_->EventReady(slot, current_timestamp_); | ||
| NotifyConsumersIfHandlersRegistered(); | ||
| std::ignore = NotifyConsumersIfHandlersRegistered(); |
Contributor
Author
There was a problem hiding this comment.
Maybe missing error handling
castler
commented
Jun 16, 2026
| const bool is_read_write{true}; | ||
|
|
||
| method_resources_.CleanUpOldRegions(proxy_instance_identifier, proxy_pid); // Per Proxy | ||
| std::ignore = method_resources_.CleanUpOldRegions(proxy_instance_identifier, proxy_pid); // Per Proxy |
castler
commented
Jun 16, 2026
| return binding_service_type_deployment.events_; | ||
| } | ||
| else if constexpr (service_element_type == ServiceElementType::FIELD) | ||
| if constexpr (service_element_type == ServiceElementType::EVENT) |
Contributor
Author
There was a problem hiding this comment.
This change does not make sense most certainly
castler
commented
Jun 16, 2026
| return lola_service_instance_deployment.events_; | ||
| } | ||
| else if constexpr (service_element_type == ServiceElementType::FIELD) | ||
| if constexpr (service_element_type == ServiceElementType::EVENT) |
Contributor
Author
There was a problem hiding this comment.
Most certainly revert
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.