_DIAGASSERT(3) | NetBSD Library Functions Manual | _DIAGASSERT(3) |
This behaviour may be changed by setting the LIBC_DIAGASSERT environment variable (see below).
The diagnostic message consists of the text of the expression, the name of the source file, the line number and the enclosing function.
If expression is true, the _DIAGASSERT() macro does nothing.
The _DIAGASSERT() macro is not compiled in by default, and will only be compiled in with the cc(1) option -D_DIAGNOSTIC.
This macro is used in the various system libraries such as the Standard C Library (libc, -lc) to ensure that various library calls are invoked with valid arguments.
LIBC_DIAGASSERT may be set to one or more of the following characters:
"assertion \"%s\" failed: file \"%s\", line %d, function \"%s\"\n", "expression", __FILE__, __LINE__, __func__
January 22, 2007 | NetBSD 5.99 |