From b449429418f2de14f5deae434dc42912d1453d12 Mon Sep 17 00:00:00 2001 From: neal Date: Wed, 17 Oct 2007 12:55:08 +0000 Subject: 2007-10-17 Neal H. Walfield * assert.h [_L4_TEST_ENVIRONMENT]: Include the next . --- libc-parts/ChangeLog | 4 ++++ libc-parts/assert.h | 20 +++++++++++++------- 2 files changed, 17 insertions(+), 7 deletions(-) (limited to 'libc-parts') diff --git a/libc-parts/ChangeLog b/libc-parts/ChangeLog index 2622f81..f792f7c 100644 --- a/libc-parts/ChangeLog +++ b/libc-parts/ChangeLog @@ -1,3 +1,7 @@ +2007-10-17 Neal H. Walfield + + * assert.h [_L4_TEST_ENVIRONMENT]: Include the next . + 2005-01-12 Neal H. Walfield * assert.h: Include prototype for printf. diff --git a/libc-parts/assert.h b/libc-parts/assert.h index 591a38f..8172ba0 100644 --- a/libc-parts/assert.h +++ b/libc-parts/assert.h @@ -1,5 +1,5 @@ /* assert.h - Assert declaration for libc-parts. - Copyright (C) 2003, 2005 Free Software Foundation, Inc. + Copyright (C) 2003, 2005, 2007 Free Software Foundation, Inc. Written by Neal H. Walfield . This file is part of the GNU Hurd. @@ -24,8 +24,12 @@ int printf (const char *fmt, ...); -#ifndef NDEBUG -#define assert(expr) \ +#ifdef _L4_TEST_ENVIRONMENT +# include_next +#else + +# ifndef NDEBUG +# define assert(expr) \ do { \ if (! (expr)) \ { \ @@ -34,9 +38,11 @@ int printf (const char *fmt, ...); for (;;); \ } \ } while (0) -#else -#define assert(expr) do { } while (0) -#endif -#define assert_perror(err) assert(err == 0) +# else +# define assert(expr) do { } while (0) +# endif +# define assert_perror(err) assert(err == 0) + +#endif /* _L4_TEST_ENVIRONMENT */ #endif /* _ASSERT_H */ -- cgit v1.2.3