Skip to content

mtu/endpoint_updater.go: Check for unix.EINVAL not os.ErrInvalid #39658

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

dylandreimerink
Copy link
Member

Initially we checked for os.ErrInvalid, this is because it produces the same string. However, os.ErrInvalid is defined in a OS independent way in terms of an fs.ErrInvalid, so it does not actually match the -EINVAL error that we want to check for.

@dylandreimerink dylandreimerink requested a review from a team as a code owner May 21, 2025 11:21
@dylandreimerink dylandreimerink added the release-note/misc This PR makes changes that have no direct user impact. label May 21, 2025
@dylandreimerink dylandreimerink requested a review from ldelossa May 21, 2025 11:21
@dylandreimerink dylandreimerink added the needs-backport/1.17 This PR / issue needs backporting to the v1.17 branch label May 21, 2025
Copy link
Contributor

@ldelossa ldelossa left a comment

Choose a reason for hiding this comment

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

LGTM

@tklauser
Copy link
Member

tklauser commented Jun 3, 2025

/test

@tklauser tklauser enabled auto-merge June 3, 2025 09:54
@dylandreimerink
Copy link
Member Author

Hmm, the IPsec tests are failing with IPSec requires IPv4 addressing to be enabled (--enable-ipv4=\"true\") seems like a mismatch between code assertions and the test. Will see if a rebase fixes it.

Initially we checked for os.ErrInvalid, this is because it produces
the same string. However, os.ErrInvalid is defined in a OS independent
way in terms of an fs.ErrInvalid, so it does not actually match the
-EINVAL error that we want to check for.

Signed-off-by: Dylan Reimerink <dylan.reimerink@isovalent.com>
@dylandreimerink dylandreimerink force-pushed the feature/endpoint-mtu-updater-handle-netns-einval branch from 41507cb to 3705392 Compare June 3, 2025 11:25
@tklauser
Copy link
Member

tklauser commented Jun 3, 2025

/test

@tklauser tklauser added this pull request to the merge queue Jun 3, 2025
@maintainer-s-little-helper maintainer-s-little-helper bot added the ready-to-merge This PR has passed all tests and received consensus from code owners to merge. label Jun 3, 2025
Merged via the queue into cilium:main with commit 3c5828b Jun 3, 2025
68 checks passed
@tklauser tklauser mentioned this pull request Jun 3, 2025
3 tasks
@tklauser tklauser added backport-pending/1.17 The backport for Cilium 1.17.x for this PR is in progress. and removed needs-backport/1.17 This PR / issue needs backporting to the v1.17 branch labels Jun 3, 2025
@github-actions github-actions bot added backport-done/1.17 The backport for Cilium 1.17.x for this PR is done. and removed backport-pending/1.17 The backport for Cilium 1.17.x for this PR is in progress. labels Jun 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport-done/1.17 The backport for Cilium 1.17.x for this PR is done. ready-to-merge This PR has passed all tests and received consensus from code owners to merge. release-note/misc This PR makes changes that have no direct user impact.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants