httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Randy Terbush <ra...@zyzzyva.com>
Subject Cleanup patches
Date Tue, 28 May 1996 03:02:59 GMT

I have the following patches to cleanup some -Wall warnings.
At least one real bug in the version of mod_auth_pg95.c that
I had.

*** http_bprintf.c.orig	Mon May 27 21:41:56 1996
--- http_bprintf.c	Mon May 27 21:49:21 1996
***************
*** 62,69 ****
      {
      const char *f,*fStop,*percentPtr,*p;
      char *fmtBuffPtr, *buffPtr;
!     int op, performedOp, sizeModifier, buffCount, buffLen, specifierLength;
!     int fastPath, n, auxBuffLen, buffReqd, minWidth, precision, exp;
      char *auxBuffPtr = NULL;
      int streamCount = 0;
      char fmtBuff[FMT_BUFFLEN];
--- 62,69 ----
      {
      const char *f,*fStop,*percentPtr,*p;
      char *fmtBuffPtr, *buffPtr;
!     int op, performedOp, sizeModifier, buffCount = 0, buffLen, specifierLength;
!     int fastPath, n, auxBuffLen = 0, buffReqd, minWidth, precision, exp;
      char *auxBuffPtr = NULL;
      int streamCount = 0;
      char fmtBuff[FMT_BUFFLEN];
***************
*** 75,87 ****
      unsigned unsignedArg;
      unsigned long uLongArg;
      unsigned short uShortArg;
!     char *charPtrArg;
      void *voidPtrArg;
      int *intPtrArg;
      long *longPtrArg;
      short *shortPtrArg;
!     double doubleArg;
!     LONG_DOUBLE lDoubleArg;
  
      fmtBuff[0] = '%';
      f=format;
--- 75,87 ----
      unsigned unsignedArg;
      unsigned long uLongArg;
      unsigned short uShortArg;
!     char *charPtrArg = '\0';
      void *voidPtrArg;
      int *intPtrArg;
      long *longPtrArg;
      short *shortPtrArg;
!     double doubleArg = .0;
!     LONG_DOUBLE lDoubleArg = .0;
  
      fmtBuff[0] = '%';
      f=format;
*** mod_auth_anon.c.orig	Mon May 27 21:57:55 1996
--- mod_auth_anon.c	Mon May 27 21:56:37 1996
***************
*** 262,280 ****
      
  int check_anon_access (request_rec *r) {
  
      conn_rec *c = r->connection;
      anon_auth_config_rec *sec =
        (anon_auth_config_rec *)get_module_config (r->per_dir_config,
  						&anon_auth_module);
  	
- /*
      if (!sec->auth_anon) return DECLINED;
  
      if ( strcasecmp(r->connection->user,sec->auth_anon ))
       	return DECLINED;
  
     return OK;
! */
     return DECLINED;
  }
   
--- 262,280 ----
      
  int check_anon_access (request_rec *r) {
  
+ #ifdef NOTYET
      conn_rec *c = r->connection;
      anon_auth_config_rec *sec =
        (anon_auth_config_rec *)get_module_config (r->per_dir_config,
  						&anon_auth_module);
  	
      if (!sec->auth_anon) return DECLINED;
  
      if ( strcasecmp(r->connection->user,sec->auth_anon ))
       	return DECLINED;
  
     return OK;
! #endif
     return DECLINED;
  }
   
*** mod_auth_msql.c.orig	Mon May 27 21:38:34 1996
--- mod_auth_msql.c	Mon May 27 21:41:24 1996
***************
*** 440,445 ****
--- 440,446 ----
      return sec;
  }
  
+ static
  char *set_passwd_flag (cmd_parms *cmd, msql_auth_config_rec *sec, int arg) {
      sec->auth_msql_nopasswd=arg;
      return NULL;
***************
*** 651,657 ****
  	/* if we have a it, try to get it
  	*/
          if ( hit )  {
! 		if (currow=msqlFetchRow(results)) {
  			/* copy the first matching field value */
  			if (!(result=palloc(r->pool,strlen(currow[0])+1))) {
  				sprintf (msql_errstr,"mSQL: Could not get memory for mSQL %s (%s) with [%s]",
--- 652,658 ----
  	/* if we have a it, try to get it
  	*/
          if ( hit )  {
! 		if ((currow=msqlFetchRow(results))) {
  			/* copy the first matching field value */
  			if (!(result=palloc(r->pool,strlen(currow[0])+1))) {
  				sprintf (msql_errstr,"mSQL: Could not get memory for mSQL %s (%s) with [%s]",
***************
*** 766,772 ****
        (msql_auth_config_rec *)get_module_config (r->per_dir_config,
  						&msql_auth_module);
      conn_rec *c = r->connection;
!     char *sent_pw, *real_pw, *colon_pw;
      int res;
  
  
--- 767,773 ----
        (msql_auth_config_rec *)get_module_config (r->per_dir_config,
  						&msql_auth_module);
      conn_rec *c = r->connection;
!     char *sent_pw, *real_pw;
      int res;
  
  
***************
*** 860,866 ****
      array_header *reqs_arr = requires (r);
      require_line *reqs = reqs_arr ? (require_line *)reqs_arr->elts : NULL;
  
!     register int x,res;
      char *t, *w;
  
  
--- 861,867 ----
      array_header *reqs_arr = requires (r);
      require_line *reqs = reqs_arr ? (require_line *)reqs_arr->elts : NULL;
  
!     register int x;
      char *t, *w;
  
  
*** mod_auth_pg95.c.orig	Mon May 27 21:39:11 1996
--- mod_auth_pg95.c	Mon May 27 21:53:36 1996
***************
*** 167,172 ****
--- 167,173 ----
  
  }
  
+ static
  char *set_passwd_flag (cmd_parms *cmd, pg_auth_config_rec *sec, int arg) {
      sec->auth_pg_nopasswd=arg;
      return NULL;
***************
*** 366,372 ****
  		);
  
  	if (sec->auth_pg_grp_whereclause)
! 		sprintf(query, "%s %s", sec->auth_pg_grp_whereclause);
  
  	return do_pg_query(r,query,sec);
  }	   
--- 367,373 ----
  		);
  
  	if (sec->auth_pg_grp_whereclause)
! 		sprintf(query, "%s %s", query, sec->auth_pg_grp_whereclause);
  
  	return do_pg_query(r,query,sec);
  }	   
***************
*** 378,384 ****
        (pg_auth_config_rec *)get_module_config (r->per_dir_config,
  						&pg95_auth_module);
      conn_rec *c = r->connection;
!     char *sent_pw, *real_pw, *colon_pw;
      int res;
      
      pg_errstr[0]='\0';
--- 379,385 ----
        (pg_auth_config_rec *)get_module_config (r->per_dir_config,
  						&pg95_auth_module);
      conn_rec *c = r->connection;
!     char *sent_pw, *real_pw;
      int res;
      
      pg_errstr[0]='\0';
*** mod_status.c.orig	Mon May 27 21:59:03 1996
--- mod_status.c	Mon May 27 21:58:44 1996
***************
*** 102,109 ****
  
  void format_byte_out(request_rec *r,unsigned long bytes)
  {
-     char ss[20];
- 
      if (bytes < (5 * KBYTE))
  	rprintf(r,"%d B",(int)bytes);
      else if (bytes < (MBYTE / 2))
--- 102,107 ----



Mime
View raw message