Page MenuHomeFreeBSD

tcp: need default in switch statement for enum.
ClosedPublic

Authored by rscheff on Feb 25 2024, 6:39 PM.
Tags
None
Referenced Files
Unknown Object (File)
Sat, May 4, 11:02 PM
Unknown Object (File)
Fri, May 3, 9:16 PM
Unknown Object (File)
Sun, Apr 14, 5:42 PM
Unknown Object (File)
Mon, Apr 8, 10:41 PM
Unknown Object (File)
Apr 5 2024, 4:41 AM
Unknown Object (File)
Feb 27 2024, 12:35 AM
Unknown Object (File)
Feb 26 2024, 1:31 AM
Subscribers

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

This will fix the compiler complaints. Is nothing the right thing to do when we don't know the type? Or is this an artifact of how the type is defined where the compiler thinks its a simple enum, when in fact it isn't....

Apparently I've only checked clang or gccc12 but ont gcc13 - where there are subtle differences in what these compilers consider acceptable;

e.g. clang is fine with impicit typecast from enum to int32, but gcc13 isn't; but once the type is enum, locally my compiler (don't really know if its using gcc12 or clang) accept it without a default clause, but the CI compile jobs fail (and I don't know why this isn't the case locally).

This revision was not accepted when it landed; it landed in state Needs Review.Feb 25 2024, 7:09 PM
This revision was automatically updated to reflect the committed changes.