Commit Graph

11 Commits

Author SHA1 Message Date
pooka 018bb97124 Rename __assert() to __kernassert() so that it doesn't collide
with the libc version.  They take different arguments.
2007-09-24 14:19:03 +00:00
ad 7dcf597b04 Do the panicstr check only if _KERNEL. 2007-08-03 13:06:00 +00:00
ad 480f8d26c5 Disable kernel assertions if panicstr != NULL. 2007-07-29 11:46:02 +00:00
christos 95e1ffb156 merge ktrace-lwp. 2005-12-11 12:16:03 +00:00
dsl 4f6d146592 KNF 2005-03-12 16:39:41 +00:00
provos 0f09ed48a5 remove trailing \n in panic(). approved perry. 2002-09-27 15:35:29 +00:00
simonb 4ca596f6a0 Don't prototype __assert() if not STANDALONE - <sys/systm.h> has already
included <lib/libkern/libkern.h> to get the prototype by this stage.

XXX: should we just change <sys/systm.h> from
	#ifdef _KERNEL
	#include <sys/systm.h>
	#endif
     to
	#if defined(_KERNEL) || defined(_STANDALONE)
	#include <sys/systm.h>
	#endif
     anyways?
2000-03-29 03:19:52 +00:00
drochner 2269d36c97 make libkern compile in userland - for testing purposes 1999-04-13 19:00:30 +00:00
pk 14b924800a Can't include libkern.h twice which is what happens if _KERNEL is on.
For now, protect here with _STANDALONE.
XXX - must probably fix sys/systm.h
1999-02-11 15:39:31 +00:00
pk a24b899029 Pull libkern.h in. 1999-02-11 09:13:03 +00:00
cgd bdbfa48c0b Add machine-independent assertion-checking support. macros are:
assert()	which always does assertion checking
			unless "NDEBUG" is defined.

	KASSERT()	which does assertion checking if DIAGNOSTIC
			is defined.

	KDASSERT()	which does assertion checking if DEBUG is
			define.  This macro exists for compatibility
			with existing ports' assertion checking macros.
			(Assertion checking is not typically an
			"expensive" operation, and DIAGNOSTIC should be
			used for inexpensive consistency checks.)
1996-08-27 00:44:20 +00:00