| Previous | Next |
| ECHRNG | EL2HLT |
ESOCKTNOSUPPORT
The type is the unsupported part of socket creation
ESOCKTNOSUPPORT identifies a socket type that the target family does not provide. Socket type controls message semantics such as stream versus datagram delivery; it is not merely a performance preference that can be swapped silently.
POSIX documents historical variation among ESOCKTNOSUPPORT, EPROTONOSUPPORT, and EPROTOTYPE when applications request unsupported type/protocol combinations. For diagnosis, preserve the full triple instead of assuming that the name alone always pins down the failing field.
Checks that matter
- Log the requested domain, type bits, protocol number, and any flags combined into the type argument.
- Verify that a portability wrapper did not request a type that exists on one operating system but not on the target family in macOS.
- Keep type selection separate from later endpoint selection. Changing a hostname or port cannot make an unsupported local socket type available.
Choosing a substitute requires protocol design work
Replacing a stream socket with a datagram socket, or vice versa, changes ordering, message boundaries, retry behavior, and error handling. A fallback is valid only when the application protocol was designed for those different semantics.
References
Looking for a different code? Search another status or error code.