In collectd 5.2.0's exec.c, it appears there is a copy-paste error in a comment:

   482      /* Connect the `in' pipe to STDIN */
   483      if (fd_pipe_in[0] != STDIN_FILENO)
   484      {
   485        dup2 (fd_pipe_in[0], STDIN_FILENO);
   486        close (fd_pipe_in[0]);
   487      }
   488
   489      /* Now connect the `out' pipe to STDOUT */
   490      if (fd_pipe_out[1] != STDOUT_FILENO)
   491      {
   492        dup2 (fd_pipe_out[1], STDOUT_FILENO);
   493        close (fd_pipe_out[1]);
   494      }
   495
   496      /* Now connect the `out' pipe to STDOUT */
   497      if (fd_pipe_err[1] != STDERR_FILENO)
   498      {
   499        dup2 (fd_pipe_err[1], STDERR_FILENO);
   500        close (fd_pipe_err[1]);
   501      }

Shoudn't line 496 refer to 'err' and 'STDERR'?

Thanks,

Robert Riches

_______________________________________________
collectd mailing list
[email protected]
http://mailman.verplant.org/listinfo/collectd

Reply via email to