Skip to content

Add excludePort option#5

Merged
wwqgtxx merged 1 commit into
MetaCubeX:metafrom
okhowang:meta
Apr 7, 2025
Merged

Add excludePort option#5
wwqgtxx merged 1 commit into
MetaCubeX:metafrom
okhowang:meta

Conversation

@okhowang
Copy link
Copy Markdown

@okhowang okhowang commented Apr 2, 2025

prepare for MetaCubeX/mihomo#1769

Comment thread tun_linux.go Outdated
@@ -474,6 +474,26 @@ func (t *NativeTun) rules() []*netlink.Rule {
}

nopPriority := ruleStart + 10
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Should the +10 here be changed to +11?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

the 10 is keep for other rules.
if rule's length greater than 10, the nopPriority will be overlapped.
it shouldn't be hardcode by 10.

Copy link
Copy Markdown

@wwqgtxx wwqgtxx Apr 5, 2025

Choose a reason for hiding this comment

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

You added a port rule here, so should change +10 to +11 to ensure that there is no overlap.
Hard coding may not be the best solution, but it does work.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

Fixed

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants