hgomez      2004/04/04 23:54:58

  Modified:    jk/native2/common jk_uriEnv.c
  Log:
  - Adds 'debug' and 'disabled' to the get and set properties functions.

  - Removes 'path' from the getAttrInfo list.

  

  Provided by NormW
  
  Revision  Changes    Path
  1.56      +34 -24    jakarta-tomcat-connectors/jk/native2/common/jk_uriEnv.c
  
  Index: jk_uriEnv.c
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat-connectors/jk/native2/common/jk_uriEnv.c,v
  retrieving revision 1.55
  retrieving revision 1.56
  diff -u -r1.55 -r1.56
  --- jk_uriEnv.c       21 Mar 2004 09:43:09 -0000      1.55
  +++ jk_uriEnv.c       5 Apr 2004 06:54:58 -0000       1.56
  @@ -182,12 +182,13 @@
   
   static char *getAttInfo[] =
       { "host", "uri", "group", "context", "inheritGlobals",
  -    "match_type",
  -    "servlet", "timing", "aliases", "path", NULL
  +    "match_type", "servlet", "timing", "aliases", "debug", "disabled",
  +    NULL
   };
   static char *setAttInfo[] =
       { "host", "uri", "group", "context", "inheritGlobals",
  -    "servlet", "timing", "alias", "path", NULL
  +    "servlet", "timing", "alias", "path", "debug", "disabled", 
  +    NULL
   };
   
   static char *matchTypes[] = {
  @@ -242,7 +243,12 @@
       else if (strcmp("inheritGlobals", name) == 0) {
           return jk2_env_itoa(env, uriEnv->inherit_globals);
       }
  -    return NULL;
  +    else if (strcmp(name, "debug") == 0) {
  +        return jk2_env_itoa(env, bean->debug);
  +    }
  +    else if (strcmp(name, "disabled") == 0) {
  +        return jk2_env_itoa(env, bean->disabled);
  +    }    return NULL;
   }
   
   
  @@ -297,27 +303,31 @@
       else if (strcmp("inheritGlobals", name) == 0) {
           uriEnv->inherit_globals = atoi(val);
       }
  -    else {
  +    else if (strcmp("worker", name) == 0) {
           /* OLD - DEPRECATED */
  -        if (strcmp("worker", name) == 0) {
  -            uriEnv->workerName = val;
  -            env->l->jkLog(env, env->l, JK_LOG_INFO,
  -                          "uriEnv.setAttribute() the %s directive is deprecated. 
Use 'group' instead.\n",
  -                          name);
  -        }
  -        else if (strcmp("uri", name) == 0) {
  -            jk2_uriEnv_parseName(env, uriEnv, val);
  -        }
  -        else if (strcmp("name", name) == 0) {
  -            jk2_uriEnv_parseName(env, uriEnv, val);
  -        }
  -        else if (strcmp("vhost", name) == 0) {
  -            if (val == NULL)
  -                uriEnv->virtual = NULL;
  -            else
  -                uriEnv->virtual =
  -                    uriEnv->pool->pstrdup(env, uriEnv->pool, val);
  -        }
  +       
  +             uriEnv->workerName = val;
  +        env->l->jkLog(env, env->l, JK_LOG_INFO,
  +                      "uriEnv.setAttribute() the %s directive is deprecated. Use 
'group' instead.\n",
  +                      name);
  +    }
  +    else if (strcmp("uri", name) == 0) {
  +        jk2_uriEnv_parseName(env, uriEnv, val);
  +    }
  +    else if (strcmp("name", name) == 0) {
  +        jk2_uriEnv_parseName(env, uriEnv, val);
  +    }
  +    else if (strcmp("vhost", name) == 0) {
  +        if (val == NULL)
  +            uriEnv->virtual = NULL;
  +         else
  +            uriEnv->virtual = uriEnv->pool->pstrdup(env, uriEnv->pool, val);
  +    }
  +    else if (strcmp(name, "debug") == 0) {
  +        mbean->debug = atoi(val);
  +    }
  +    else if (strcmp(name, "disabled") == 0) {
  +        mbean->disabled = atoi(val);
       }
       return JK_OK;
   }
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to