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

subnet/config.go: Fix handling of subnet config #896

Merged
merged 1 commit into from
Jan 2, 2018

Conversation

tomdee
Copy link
Contributor

@tomdee tomdee commented Dec 7, 2017

Fix all the limits, especially around minimum sizes

Fixes #696

subnet/config.go Outdated
// try to give each host a /24 but if the whole network
// is /24 or smaller, half the network
// try to give each host a /24 but if the whole network is /24 or smaller, split the network into four.
// the first subnet isn't used, so splitting into two one only provide one usable host.
if cfg.Network.PrefixLen < 24 {
Copy link
Contributor

Choose a reason for hiding this comment

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

shouldn't this be <= according to the comment?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@gunjan5 I updated the comments and code on these lines. PTAL.

Fix all the limits, especially around minimum sizes

Fixes flannel-io#696
@tomdee tomdee force-pushed the fix-subnet-checking branch from 2894d74 to 4485ecd Compare December 13, 2017 00:58
Copy link
Contributor

@gunjan5 gunjan5 left a comment

Choose a reason for hiding this comment

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

LGTM 🤠

@gunjan5 gunjan5 merged commit e8e4de7 into flannel-io:master Jan 2, 2018
@tomdee tomdee deleted the fix-subnet-checking branch January 7, 2018 01:27
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