On Tue, 22 Mar 2005 13:08:04 +0100, Henri Schomäcker
<[EMAIL PROTECTED]> wrote:
> Hi folks,
> 
> I have a problem getting the environment variables with apr_env_get in 
> the request handler of my module.
> What I need are HTTP_USER_AGENT and REMOTE_ADDRESS but I just don't get 
> anything as a resullt in my char*.

The Apache "environment variables" are not available within the Apache
process via getenv.  Instead, do a lookup in the table
r->subprocess_env.

If you search through the Apache source code for the string
subprocess_env, you'll see numerous examples.  Here's one from
mod_unique_id:

apr_table_get(r->subprocess_env,
              "REDIRECT_UNIQUE_ID")

Reply via email to