X-Git-Url: https://ncurses.scripts.mit.edu/?p=ncurses.git;a=blobdiff_plain;f=test%2Ftest.priv.h;h=f856f618f0bd87aa28c0b0104eed912d1e095258;hp=50b6effbb383783f2e9f20c1820b8503ee61b9eb;hb=c04d54322f7835ed42e597967d8fa5471025fcac;hpb=dfaa1a3001fd447819f5edc2e523acc1a04f1440 diff --git a/test/test.priv.h b/test/test.priv.h index 50b6effb..f856f618 100644 --- a/test/test.priv.h +++ b/test/test.priv.h @@ -29,7 +29,7 @@ /**************************************************************************** * Author: Thomas E. Dickey 1996-on * ****************************************************************************/ -/* $Id: test.priv.h,v 1.91 2009/07/18 12:19:23 tom Exp $ */ +/* $Id: test.priv.h,v 1.93 2009/10/24 21:30:13 tom Exp $ */ #ifndef __TEST_PRIV_H #define __TEST_PRIV_H 1 @@ -222,6 +222,7 @@ #include #include #include +#include #if HAVE_UNISTD_H #include @@ -643,6 +644,15 @@ typedef int (*NCURSES_SCREEN_CB)(SCREEN *, void *); #define USE_TRACE 0 #endif +/* + * Workaround for defective implementation of gcc attribute warn_unused_result + */ +#if defined(__GNUC__) && defined(_FORTIFY_SOURCE) +#define IGNORE_RC(func) errno = func +#else +#define IGNORE_RC(func) (void) func +#endif /* gcc workarounds */ + #define init_mb(state) memset(&state, 0, sizeof(state)) #endif /* __TEST_PRIV_H */