diff options
author | Arthur de Jong <arthur@arthurdejong.org> | 2012-10-13 13:35:46 +0000 |
---|---|---|
committer | Arthur de Jong <arthur@arthurdejong.org> | 2012-10-13 13:35:46 +0000 |
commit | 9c083a994166b9b726e5757768fa7da694fdbd2e (patch) | |
tree | f66b5ddc60294cc3d543dee8ac346646e1b70f4c /tests | |
parent | fff84e239d7dd7f449791e5dfbb3b94608be29d3 (diff) |
provide alternatives for assertion failures on Solaris and FreeBSD
git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-pam-ldapd@1787 ef36b2f9-881f-0410-afb5-c4e39611909c
Diffstat (limited to 'tests')
-rw-r--r-- | tests/common.h | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/tests/common.h b/tests/common.h index 68490e6..1c0b96e 100644 --- a/tests/common.h +++ b/tests/common.h @@ -2,7 +2,7 @@ common.h - common test routines This file is part of the nss-pam-ldapd library. - Copyright (C) 2011 Arthur de Jong + Copyright (C) 2011, 2012 Arthur de Jong This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public @@ -32,7 +32,13 @@ /* try to find the actual assert function */ #ifndef HAVE___ASSERT_FAIL /* for Solaris: */ +#ifdef sun #define __assert_fail(assertion,file,line,function) __assert(assertion,file,line) +#endif +/* for FreeBSD: */ +#ifdef __FreeBSD__ +#define __assert_fail(assertion,file,line,function) __assert(assertion,file,line,function) +#endif #endif /* not HAVE___ASSERT_FAIL */ /* extra assertion function that epxects both strings to be the same |