[torquedev] patch: qsub.c - fclose() should be pclose() for filter_pipe

Glen Beane glen.beane at gmail.com
Tue Feb 27 08:38:34 MST 2007


thanks. I will update trunk and 2.1-fixes

On 2/27/07, Toni L. Harbaugh-Blackford [Contr] <harbaugh at ncifcrf.gov> wrote:
>
> In qsub.c, the submit filter pipe is opened with popen() but closed
> with fclose().  While this still appears to work on linux, it does
> not work on IRIX because the exit value of the pipe is not returned.
> The fix is to close the pipe with pclose(), which still works on linux:
>
>
> --- torque-2.2.0-snap.200611291634/src/cmds/qsub.c_orig Wed Nov 29 18:34:48 2006
> +++ torque-2.2.0-snap.200611291634/src/cmds/qsub.c      Tue Feb 27 10:27:02 2007
> @@ -502,7 +502,7 @@
>          }
>        }
>
> -    rc = fclose(filter_pipe);
> +    rc = pclose(filter_pipe);
>
>      if (WEXITSTATUS(rc) == (unsigned char)SUBMIT_FILTER_ADMIN_REJECT_CODE)
>        {
>
> -------------------------------------------------------------------
> Toni Harbaugh-Blackford                   harbaugh at abcc.ncifcrf.gov
> System Administrator
> Advanced Biomedical Computing Center (ABCC)
> National Cancer Institute
> Contractor - SAIC/Frederick
> _______________________________________________
> torquedev mailing list
> torquedev at supercluster.org
> http://www.supercluster.org/mailman/listinfo/torquedev
>


More information about the torquedev mailing list