tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cos...@apache.org
Subject cvs commit: jakarta-tomcat-connectors/jk/native2/server/apache2 mod_jk2.c
Date Wed, 19 Jun 2002 18:27:25 GMT
costin      2002/06/19 11:27:25

  Modified:    jk/native2/common jk_channel_socket.c
               jk/native2/server/apache2 mod_jk2.c
  Log:
  Use read/write instead of send/receive. The error handling/reporting is much
  simpler, and we don't need any of the advanced features of send/receive().
  
  Small fix in apache2 dir merge, needed if <Location>/JkUriSet is used.
  
  Revision  Changes    Path
  1.33      +7 -9      jakarta-tomcat-connectors/jk/native2/common/jk_channel_socket.c
  
  Index: jk_channel_socket.c
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat-connectors/jk/native2/common/jk_channel_socket.c,v
  retrieving revision 1.32
  retrieving revision 1.33
  diff -u -r1.32 -r1.33
  --- jk_channel_socket.c	10 Jun 2002 21:55:06 -0000	1.32
  +++ jk_channel_socket.c	19 Jun 2002 18:27:25 -0000	1.33
  @@ -333,7 +333,7 @@
    * @param len length to send.
    * @return    -2: send returned 0 ? what this that ?
    *            -3: send failed.
  - *            >0: total size send.
  + *            JK_OK: success
    * @bug       this fails on Unixes if len is too big for the underlying
    *             protocol.
    * @was: jk_tcp_socket_sendfull
  @@ -357,8 +357,8 @@
   
       
       while(sent < len) {
  -        int this_time = send(sd, (char *)b + sent , len - sent,  0);
  -	    
  +        int this_time = write(sd, (char *)b + sent , len - sent);
  +        fprintf(stderr, "WRITE: %d %d %d\n", this_time, len, errno);
   	if(0 == this_time) {
   	    return -2;
   	}
  @@ -394,10 +394,9 @@
       if( sd<0 ) return JK_ERR;
       
       while(rdlen < len) {
  -	int this_time = recv(sd, 
  +	int this_time = read(sd, 
   			     (char *)b + rdlen, 
  -			     len - rdlen, 
  -			     0);	
  +			     len - rdlen);	
   	if(-1 == this_time) {
   #ifdef WIN32
   	    if(SOCKET_ERROR == this_time) { 
  @@ -432,10 +431,9 @@
       if( sd<0 ) return JK_ERR;
       
       while(rdlen < minLen ) {
  -	int this_time = recv(sd, 
  +	int this_time = read(sd, 
   			     (char *)b + rdlen, 
  -			     maxLen - rdlen, 
  -			     0);
  +			     maxLen - rdlen);
   /*         fprintf(stderr, "XXX received %d\n", this_time ); */
   	if(-1 == this_time) {
   #ifdef WIN32
  
  
  
  1.37      +4 -1      jakarta-tomcat-connectors/jk/native2/server/apache2/mod_jk2.c
  
  Index: mod_jk2.c
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat-connectors/jk/native2/server/apache2/mod_jk2.c,v
  retrieving revision 1.36
  retrieving revision 1.37
  diff -u -r1.36 -r1.37
  --- mod_jk2.c	10 Jun 2002 21:55:08 -0000	1.36
  +++ mod_jk2.c	19 Jun 2002 18:27:25 -0000	1.37
  @@ -215,6 +215,9 @@
       jk_uriEnv_t *child =(jk_uriEnv_t *)childv;
       jk_uriEnv_t *parent = (jk_uriEnv_t *)parentv; 
   
  +    if( child->uri==NULL )
  +        return parentv;
  +    
       if( child->merged != JK_TRUE ) {
           /* Merge options from parent. 
            */
  
  
  

--
To unsubscribe, e-mail:   <mailto:tomcat-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:tomcat-dev-help@jakarta.apache.org>


Mime
View raw message