Date: Wed, 21 May 2025 08:28:39 +0100 From: Lexi Winter <ivy@FreeBSD.org> To: Poul-Henning Kamp <phk@phk.freebsd.dk> Cc: FreeBSD CURRENT <freebsd-current@freebsd.org> Subject: Re: Un-sucking EINVAL (was: ip# on bridge members) Message-ID: <aC2Ap5ogfrlC-kHn@ragweed.eden.le-fay.org> In-Reply-To: <202505210722.54L7MTqw025632@critter.freebsd.dk> References: <aC0CgBBWrodf6pa8@ragweed.eden.le-fay.org> <202505210722.54L7MTqw025632@critter.freebsd.dk>
index | next in thread | previous in thread | raw e-mail
[-- Attachment #1 --] Poul-Henning Kamp: > The ip# on bridge member interfaces is yet another example of why > "EINVAL" is the undisputedly least helpful errno of them all. > > The laconic "Invalid argument" leaves both the userland programmer > and the user to guess what might be wrong. you are completely right. since we (for some reason, that i don't really understand) can't add new error codes to errno, we should stop using errno to indicate errors except where POSIX requires this. > We should give errno a text-partner, so kernel code can: i am open to other solutions here, but i intend to convert bridge(4) to use netlink for configuration, which allows us to return a real error message that ifconfig can print. [-- Attachment #2 --] -----BEGIN PGP SIGNATURE----- iHUEABYKAB0WIQSyjTg96lp3RifySyn1nT63mIK/YAUCaC2ApgAKCRD1nT63mIK/ YIARAP9oelK6+Xlbz+fnIq2gTtdMP/FbBh/fKw1vbw40tiScRgEA/OUPD1Brui6E Epstclm9GLBwQdgTUa6NcCiGZTPa/A4= =I8Zl -----END PGP SIGNATURE-----home | help
Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?aC2Ap5ogfrlC-kHn>
