Skip to content
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

[protobuf] Readded msg_size and field name check to ProcProtoMsg recursion #1734

Merged
merged 2 commits into from
Sep 13, 2024

Conversation

Peguen
Copy link
Contributor

@Peguen Peguen commented Sep 12, 2024

Description

To avoid infinite recursive for recursive proto definitions readded the msg_size check and additionally a field name find check. The later enables the msg to show at least one default submsg, even if every field is just a default value.

@Peguen Peguen added the cherry-pick-to-support/v5.13 Cherry pick these changes to support/v5.13 label Sep 12, 2024
Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

clang-tidy made some suggestions

ecal/msg/protobuf/src/ecal_proto_decoder.cpp Outdated Show resolved Hide resolved
ecal/msg/protobuf/src/ecal_proto_decoder.cpp Outdated Show resolved Hide resolved
ecal/msg/protobuf/src/ecal_proto_decoder.cpp Outdated Show resolved Hide resolved
Copy link
Contributor

@KerstinKeller KerstinKeller left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sounds good, as long as we avoid infinite recursion 😄

@Peguen Peguen merged commit fef124c into master Sep 13, 2024
18 of 20 checks passed
@Peguen Peguen deleted the hotfix/endless_recursion_dyn_decoder_fix branch September 13, 2024 06:12
Peguen added a commit that referenced this pull request Sep 13, 2024
…rsion (#1734)

* Added msg_size and string find check to ProcProtoMsg recursion.

* Added same logic to dyn_proto sample
Peguen added a commit that referenced this pull request Oct 2, 2024
…rsion (#1734) (#1735)

* Added msg_size and string find check to ProcProtoMsg recursion.

* Added same logic to dyn_proto sample

Co-authored-by: Peguen <73380451+Peguen@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cherry-pick-to-support/v5.13 Cherry pick these changes to support/v5.13
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants