correctly test for __GNUC__ macro (non-GCC compilers do not have it defined at all)
This commit is contained in:
parent
88b5665aec
commit
336f1ea816
@ -594,7 +594,7 @@ evalcommand(union node *cmd, int flags, struct backcmd *backcmd)
|
||||
char *lastarg;
|
||||
int realstatus;
|
||||
int do_clearcmdentry;
|
||||
#if __GNUC__
|
||||
#ifdef __GNUC__
|
||||
/* Avoid longjmp clobbering */
|
||||
(void) &argv;
|
||||
(void) &argc;
|
||||
|
@ -898,7 +898,7 @@ readtoken1(int firstc, char const *syntax, char *eofmark, int striptabs)
|
||||
int oldstyle;
|
||||
char const *prevsyntax; /* syntax before arithmetic */
|
||||
int synentry;
|
||||
#if __GNUC__
|
||||
#ifdef __GNUC__
|
||||
/* Avoid longjmp clobbering */
|
||||
(void) &out;
|
||||
(void) "ef;
|
||||
@ -1323,7 +1323,7 @@ parsebackq: {
|
||||
struct jmploc *volatile savehandler;
|
||||
int savelen;
|
||||
int saveprompt;
|
||||
#if __GNUC__
|
||||
#ifdef __GNUC__
|
||||
/* Avoid longjmp clobbering */
|
||||
(void) &saveprompt;
|
||||
#endif
|
||||
|
@ -195,7 +195,7 @@ setvarsafe(char *name, char *val, int flags)
|
||||
struct jmploc jmploc;
|
||||
struct jmploc *volatile savehandler = handler;
|
||||
int err = 0;
|
||||
#if __GNUC__
|
||||
#ifdef __GNUC__
|
||||
/* Avoid longjmp clobbering */
|
||||
(void) &err;
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user