costin      01/06/23 09:04:12

  Modified:    jk/native/common jk_ajp14_worker.c
  Log:
  Small fix - if validation fails ( like I forgot to add the secret ), then
  destroy will try to free() a constant ( since strdup didn't happened ).
  
  We set it to null, the init will fail if the user doesn't specify a valid
  option.
  
  ( the stack trace was:
  #0  0x40095ce8 in pthread_mutex_lock () from /lib/libpthread.so.0
  #1  0x401230a8 in free () from /lib/libc.so.6
  #2  0x401d2364 in destroy (pThis=0xbffff414, l=0x8165df8)
      at ../common/jk_ajp14_worker.c:156
  #3  0x401d56f8 in wc_create_worker (name=0x8168038 "ajp14", init_data=0x81674f8,
      rc=0xbffff468, we=0x401e275c, l=0x8165df8) at ../common/jk_worker.c:170
  #4 ....
  ....
  
  Revision  Changes    Path
  1.8       +2 -2      jakarta-tomcat-connectors/jk/native/common/jk_ajp14_worker.c
  
  Index: jk_ajp14_worker.c
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat-connectors/jk/native/common/jk_ajp14_worker.c,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- jk_ajp14_worker.c 2001/06/22 08:33:56     1.7
  +++ jk_ajp14_worker.c 2001/06/23 16:04:12     1.8
  @@ -58,7 +58,7 @@
   /***************************************************************************
    * Description: AJP14 next generation Bi-directional protocol.             *
    * Author:      Henri Gomez <[EMAIL PROTECTED]>                               *
  - * Version:     $Revision: 1.7 $                                           *
  + * Version:     $Revision: 1.8 $                                           *
    ***************************************************************************/
   
   #include "jk_context.h"
  @@ -299,7 +299,7 @@
        memset(aw->login, 0, sizeof(jk_login_service_t));
   
        aw->login->negociation      = (AJP14_CONTEXT_INFO_NEG | 
AJP14_PROTO_SUPPORT_AJP14_NEG);
  -     aw->login->web_server_name  = "MyApache";
  +     aw->login->web_server_name  = NULL; // must be set in init
   
       aw->ep_cache_sz            = 0;
       aw->ep_cache               = NULL;
  
  
  

Reply via email to