On Tue, 31 Mar 2009 11:21:22 +0200 Polytropon <[email protected]> wrote:
> 4. Use the predefined return codes, don't hardcode them. > FreeBSD has EXiT_SUCCESS and EXIT_FAILURE, they're for > maximum compatibility (such as with Linux). There are > more exit codes for differentiation, but they're specific > to FreeBSD, as far as I know. Linux seems to have adopted sysexits.h too, which provides error codes such as EX_USAGE and EX_CANTCREAT. However, in FreeBSD at least the most common programming style is to use 1 for error and 0 for success - e.g. from style(9): errx(1, "number overflowed"); -- Bruce Cran _______________________________________________ [email protected] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "[email protected]"
