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

[dhcp_relay] Fix sendto: invalid destination address error #9143

Merged
merged 1 commit into from
Nov 2, 2021

Conversation

kellyyeh
Copy link
Contributor

@kellyyeh kellyyeh commented Nov 2, 2021

Why I did it

Not all relay forward packets are sent to desired dhcpv6_servers.
Sendto error: invalid destination address

How I did it

Memory gets deallocated at end of loop_relay, need to allocate object on the heap.

How to verify it

Build dhcp6relay debian package and run dhcpv6 relay tests

Which release branch to backport (provide reason below if selected)

  • 201811
  • 201911
  • 202006
  • 202012
  • 202106

Description for the changelog

A picture of a cute animal (not mandatory but encouraged)

@kellyyeh kellyyeh marked this pull request as ready for review November 2, 2021 17:40
@kellyyeh kellyyeh requested a review from yxieca November 2, 2021 17:55
@kellyyeh kellyyeh merged commit 1067bc8 into master Nov 2, 2021
@lguohan
Copy link
Collaborator

lguohan commented Nov 2, 2021

why we could not catch this issue in the sonic-mgmt test?

@kellyyeh
Copy link
Contributor Author

kellyyeh commented Nov 2, 2021

@lguohan There were 4 server addresses, and only one was affected, so packets were still successfully relayed to the other three destination addresses. Sonic-mgmt only checks if >=1 expected packet is received.

@kellyyeh kellyyeh deleted the kellyyeh-dhcp6relay-fix branch November 3, 2021 22:11
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