Skip to contentSkip to conversation

dash fix for job control off warning

PATCH In review maximilian attems 2 participants 2 messages Apr 7, 2010 – Apr 15, 2010 Kbuild

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 dash fix for job control off warning

fix subject and added warning to patch mail,
thanks for review.

----- Forwarded message from "H. Peter Anvin" <[email protected]> -----

Date: Mon, 29 Mar 2010 15:07:01 -0700
From: "H. Peter Anvin" <[email protected]>
To: maximilian attems <[email protected]>
Cc: Colin Watson <[email protected]>, [email protected],
Herbert Xu <[email protected]>, Nobuhiro Iwamatsu <[email protected]>
Subject: Re: [klibc] dash fix for job control off warning

There seems to be a problem with the new version of dash with job control off. I can't tell if it is just a warning or is a manifest bug.

usr/dash/trap.c: In function `exitshell':
usr/dash/trap.c:376: warning: suggest braces around empty body in an `if' statement

The solution is simple:

usr/dash/jobs.h +1 -1
@@ -105,5 +105,5 @@ int waitforjob(struct job *);
 int stoppedjobs(void);
 
 #if ! JOBS
-#define setjobctl(on)  /* do nothing */
+#define setjobctl(on) ((void)(on))     /* do nothing */
 #endif

... to keep the code syntactically valid even when setjobctl() is used as the body of an if statement.

-hpa

----- End forwarded message -----

Signature · 1 line
maks
#1 lore raw
Quoted 13 lines · maximilian attems

fix subject and added warning to patch mail,
thanks for review.

----- Forwarded message from "H. Peter Anvin" <[email protected]> -----

Date: Mon, 29 Mar 2010 15:07:01 -0700
From: "H. Peter Anvin" <[email protected]>
To: maximilian attems <[email protected]>
Cc: Colin Watson <[email protected]>, [email protected],
Herbert Xu <[email protected]>, Nobuhiro Iwamatsu <[email protected]>
Subject: Re: [klibc] dash fix for job control off warning

Quoted 6 lines

There seems to be a problem with the new version of dash with job control off. I can't tell if it is just a warning or is a manifest bug.

usr/dash/trap.c: In function `exitshell':
usr/dash/trap.c:376: warning: suggest braces around empty body in an `if' statement

Patch applied. Thanks!

Signature · 4 lines
Visit Openswan at http://www.openswan.org/
Email: Herbert Xu ~{PmV>HI~} <[email protected]>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt