In some cases broken DHCP servers might send invalid MTU value,
so allow to use 'supersede' in dhclient.conf to override this. When
superseded value is 0, MTU value is not updated at all.
Details
Diff Detail
- Repository
- rS FreeBSD src repository - subversion
- Lint
Lint Not Applicable - Unit
Tests Not Applicable
Event Timeline
dhclient/dhclient.c | ||
---|---|---|
839–841 ↗ | (On Diff #42708) | Maybe we should still warn if the server sends zero, vs the user configuring it. But I don't feel strongly about it. |
dhclient/dhclient.conf.5 | ||
234–235 ↗ | (On Diff #42708) | It doesn't seem clear to me from the text that the special zero value only applies if supersede is specified; also it seems a little weird to put it in the "OPTION MODIFIERS" section. I'd suggest: .Pp Some options have special values: .Bl -tag -width indent .It Ar interface-mtu Any server-supplied interface MTU is ignored by the client if a .Ic supersede zero value is configured. But maybe get someone from docs to offer advice. |
dhclient/dhclient.c | ||
---|---|---|
843 ↗ | (On Diff #42730) | All of these parentheses seem excessive -- just if (!supersede || mtu == 0) would do. |
@cem I'd appreciate if you could get this committed for me. I guess it needs to be properly MFCed so it gets into 11.2, and given that timeline is tight and I'm not very familiar with the process, it'll be better to get it done right from the first attempt.
dhclient/dhclient.c | ||
---|---|---|
843 ↗ | (On Diff #42730) | This way it'll still print a warning for superseded value because 'mtu == 0' will be true. |
Sure, no problem. I'd like to see some manpages/doc team feedback; hopefully that happens soon.
I guess it needs to be properly MFCed so it gets into 11.2, and given that timeline is tight and I'm not very familiar with the process, it'll be better to get it done right from the first attempt.
I don't MFC, but maybe someone can be recruited to do it.
dhclient/dhclient.c | ||
---|---|---|
843 ↗ | (On Diff #42730) | Ah, sorry, I meant '!= 0' and I see you got that right :-). LGTM. |