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

bgpd: fix a possible crash issue (code review) #14127

Closed
wants to merge 1 commit into from
Closed

bgpd: fix a possible crash issue (code review) #14127

wants to merge 1 commit into from

Conversation

zice312963205
Copy link
Contributor

The variable 'adj' used in this loop is not assigned a new value within the loop, instead it keeps using the same 'adj' assigned earlier, which may cause an exception in the second iteration of the loop.

The variable 'adj' used in this loop is not assigned a new value within the loop, instead it keeps using the same 'adj' assigned earlier, which may cause an exception in the second iteration of the loop.

Signed-off-by: Jack.zhang <[email protected]>
@NetDEF-CI
Copy link
Collaborator

Continuous Integration Result: SUCCESSFUL

Congratulations, this patch passed basic tests

Tested-by: NetDEF / OpenSourceRouting.org CI System

CI System Testrun URL: https://ci1.netdef.org/browse/FRR-PULLREQ2-13240/

This is a comment from an automated CI system.
For questions and feedback in regards to this CI system, please feel free to email
Martin Winter - mwinter (at) opensourcerouting.org.

@ton31337 ton31337 self-requested a review August 2, 2023 08:57
@ton31337
Copy link
Member

ton31337 commented Aug 2, 2023

This is the same issue #13625.

@ton31337
Copy link
Member

ton31337 commented Aug 3, 2023

@donaldsharp had some insightful comments regarding this behavior on how adj can be NULL (in what cases).

Copy link
Member

@riw777 riw777 left a comment

Choose a reason for hiding this comment

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

looks good

@qlyoung qlyoung changed the title bgpd:fix a possible crash issue(code review) bgpd: fix a possible crash issue (code review) Aug 9, 2023
@riw777
Copy link
Member

riw777 commented Aug 22, 2023

This is the same issue #13625.

Seems like maybe we should close this one and get #13625 in?

@zice312963205
Copy link
Contributor Author

This is the same issue #13625.

Seems like maybe we should close this one and get #13625 in?

Sure. But later on, I reconsidered this issue and believed that a better approach should be used to address it. I have already provided specific comments in PR #13625 .

@zice312963205
Copy link
Contributor Author

A better approach seems to be moving the route to the withdraw queue when a larger attribute is discovered. Otherwise, if the route was previously sent with a smaller attribute, it cannot be properly updated to other neighbors, and a better way to handle it may be to withdraw the route from the neighbors.(?) Will close this PR and track it in PR #13625

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants