headers: remove definition of ASSERT from xfs.h
PATCH 1/1 headers: remove definition of ASSERT from xfs.h
From: Dave Chinner <[email protected]>
If we define ASSERT() in the installed xfs.h header file, programs including this header file will have their local definitions of ASSERT screwed up. This is something internal to the xfsprogs build, so move it to platform_defs.h.in where it will no longer be public.
--- include/platform_defs.h.in | 6 ++++++ include/xfs.h | 6 ------ 2 files changed, 6 insertions(+), 6 deletions(-)
include/platform_defs.h.in +6 -0
@@ -83,4 +83,10 @@ typedef unsigned short umode_t; #define NBBY 8 #endif +#ifdef DEBUG +# define ASSERT(EX) assert(EX) +#else +# define ASSERT(EX) ((void) 0) +#endif + #endif /* __XFS_PLATFORM_DEFS_H__ */
include/xfs.h +0 -6
@@ -47,12 +47,6 @@# error unknown platform... have fun porting!#endif -#ifdef DEBUG -# define ASSERT (EX ) assert(EX) -#else -# define ASSERT (EX ) ((void) 0) -#endif -/* * sparse kernel source annotations */
Signature · 6 lines
2.5.0 _______________________________________________ xfs mailing list [email protected] http://oss.sgi.com/mailman/listinfo/xfs
Quoted 8 lines · Dave Chinner
From: Dave Chinner <[email protected]>
If we define
ASSERT()in the installedxfs.hheader file, programs including this header file will have their local definitions of ASSERT screwed up. This is something internal to the xfsprogs build, so move it to platform_defs.h.in where it will no longer be public.Signed-off-by Dave Chinner <[email protected]>
Looks good,
_______________________________________________
xfs mailing list
[email protected]
http://oss.sgi.com/mailman/listinfo/xfs