Add a call to apr_hook_deregister_all() in the clear_module_list function. The basic problem was that when we load the modules, we call the register_hooks() function from the module, but then we clear the module list for all active modules, and add them back in one at a time. When we add them back, we re-call the register_hooks() function, thus adding each function a second time. This was causing apache.org to log every request twice in the access log. By calling apr_hook_deregister_all() when we unload the module, the second call to register the hooks is the only call that matters.
The changes required for the APR_FINFO_wanted argument to apr_stat/lstat/getfileinfo. These are -NOT- optimal, they are simply the required changes to get the server working. The size of the patch is a warning about how we need to really look at what we are trying to accomplish with all of these stat/lstat calls.