I am not at all sure I like ap_rlog_error() adding an error-notes (to r->notes) under the covers. For those that are not familer with this, if you call ap_rlog_error() for a failed request, the first call will copy your log message to the output stream sent back to the client. You can end up with stuff on the response that perhaps you didn't intend (like the full path to a CGI script that failed to run, or perhaps even unescaped user data).
I am thinking that the second arg of ap_rlog_error() should take a new option, something like APR_LOG_RESPONSE or APR_LOG_ERROR-NOTES, that tells ap_rlog_error() to add the message to error-notes. If you leave off this option, then r->notes will NOT be modified (and your error message will not be echoed back to the client). Any opinions? Bill
