apr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stefan Fritsch ...@sfritsch.de>
Subject Re: svn propchange: r747990 - svn:log
Date Tue, 03 Mar 2009 20:51:00 GMT
On Tuesday 03 March 2009, William A. Rowe, Jr. wrote:
> Let's review what -should- happen today;
>      apr_file_open_stderr(&stderr_log, p)
> should return stderr_log apr_file_t indicating the INHERIT flag
> set.

OK, this was the missing bit. apr_file_open_stderr() uses 
apr_os_file_put(), which sets APR_FILE_NOCLEANUP but not APR_INHERIT.

> Then; 
>      apr_file_dup2(stderr_log, new_file, p)
> should maintain the INHERIT flag on the newly dup2'ed stderr_log.
> Does that make sense?

The problem with the CLOEXEC-patch is that apr_file_dup2() now only 
checks for APR_INHERIT but not for APR_FILE_NOCLEANUP to determine if 
FD_CLOEXEC should be set. But APR_FILE_NOCLEANUP should imply 
APR_INHERIT and the new apr_file_dup2 needs to be changed.

When I have some free cycles, I will check if this solves the problem 
that processes exec'ed by httpd/mod_php have no stderr.


View raw message