]> git.ipfire.org Git - thirdparty/make.git/commitdiff
* job.c (child_execute_job): [SV 49938] Avoid spurious GCC warning.
authorMartin Dorey <martin.dorey@hds.com>
Mon, 26 Dec 2016 19:09:38 +0000 (14:09 -0500)
committerPaul Smith <psmith@gnu.org>
Mon, 26 Dec 2016 19:09:38 +0000 (14:09 -0500)
job.c

diff --git a/job.c b/job.c
index 7d900ce5f31496cc166ac521d0976666cdedf050..81248971b640b77a5bc2f713d22879e73335788a 100644 (file)
--- a/job.c
+++ b/job.c
@@ -2121,11 +2121,11 @@ child_execute_job (struct output *out, int good_stdin, char **argv, char **envp)
 int
 child_execute_job (struct output *out, int good_stdin, char **argv, char **envp)
 {
-  int r;
-  int pid;
-  int fdin = good_stdin ? FD_STDIN : get_bad_stdin ();
+  const int fdin = good_stdin ? FD_STDIN : get_bad_stdin ();
   int fdout = FD_STDOUT;
   int fderr = FD_STDERR;
+  int r;
+  int pid;
 
   /* Divert child output if we want to capture it.  */
   if (out && out->syncout)