Changeset 769
- Timestamp:
- 01/06/10 19:52:19 (2 months ago)
- Location:
- branches/1.1.x
- Files:
-
- 4 modified
Legend:
- Unmodified
- Added
- Removed
-
branches/1.1.x/configure
r143 r769 5664 5664 fi 5665 5665 MYSQLLIBS="-L$DST_MYSQL_LIBS -lmysqlclient" 5666 CFLAGS="-O2 -Wall -D_BSD_SOURCE=1 -D_GNU_SOURCE=1 "5666 CFLAGS="-O2 -Wall -D_BSD_SOURCE=1 -D_GNU_SOURCE=1 -D_FILE_OFFSET_BITS=64" 5667 5667 5668 5668 #### … … 5762 5762 fi 5763 5763 PCRELIBS="-L$DST_PCRE_LIBS -lpcre" 5764 CFLAGS="-O2 -Wall -D_BSD_SOURCE=1 -D_GNU_SOURCE=1"5764 #CFLAGS="-O2 -Wall -D_BSD_SOURCE=1 -D_GNU_SOURCE=1" 5765 5765 5766 5766 echo "#include \"$DST_PCRE_INC/pcre.h\"" >pcre.h -
branches/1.1.x/configure.in
r143 r769 175 175 fi 176 176 MYSQLLIBS="-L$DST_MYSQL_LIBS -lmysqlclient" 177 CFLAGS="-O2 -Wall -D_BSD_SOURCE=1 -D_GNU_SOURCE=1 "177 CFLAGS="-O2 -Wall -D_BSD_SOURCE=1 -D_GNU_SOURCE=1 -D_FILE_OFFSET_BITS=64" 178 178 179 179 #### … … 245 245 fi 246 246 PCRELIBS="-L$DST_PCRE_LIBS -lpcre" 247 CFLAGS="-O2 -Wall -D_BSD_SOURCE=1 -D_GNU_SOURCE=1"247 #CFLAGS="-O2 -Wall -D_BSD_SOURCE=1 -D_GNU_SOURCE=1" 248 248 249 249 echo "#include \"$DST_PCRE_INC/pcre.h\"" >pcre.h -
branches/1.1.x/demon.c
r564 r769 20 20 21 21 int EMPTY; 22 long ENDVALUE; 23 long NEWENDVALUE; 22 //long ENDVALUE; 23 size_t ENDVALUE; 24 size_t NEWENDVALUE; 24 25 25 26 int RIPC; … … 91 92 92 93 93 longGetNewEndValue()94 size_t GetNewEndValue() 94 95 { 95 long value; 96 FILE *finp; 96 struct stat st; 97 97 98 98 trim(&path[0]); 99 99 sprintf(&path[0],"%s/%s",conf.logdir,conf.logfile); 100 if((finp=fopen( &path[0], "rb" ))==NULL) 101 { 102 printf("Don't open file %s/%s\n",conf.logdir,conf.logfile); 103 return(0); 104 } 105 fseek(finp,0,SEEK_END); 106 value=ftell(finp); 107 fclose(finp); 108 return(value); 100 lstat(&path[0],&st); 101 return(st.st_size); 109 102 } 110 103 … … 146 139 147 140 int userflag=0; 148 doubleENDVALUE2;141 size_t ENDVALUE2; 149 142 150 143 sprintf(&path[0],"%s/%s",conf.logdir,conf.logfile); … … 857 850 if(DEBUG>0) 858 851 { 859 printf("Reading file: start=%l d length=%ld\n",ENDVALUE,NEWENDVALUE);852 printf("Reading file: start=%lu length=%lu\n",ENDVALUE,NEWENDVALUE); 860 853 } 861 854 -
branches/1.1.x/logtool.c
r738 r769 112 112 return(-1); 113 113 } 114 // if((int)str[10]!=0x2E && (int)str[14]!=0x20 && (int)str[21]!=0x20) 114 115 } 115 116 if(strlen(str)<60) … … 307 308 } 308 309 } 309 } else { 310 } 311 else 312 { 310 313 /* If user ask https page, we get url like: domain.name:443 */ 311 314 if ( pcre_exec(re, NULL, url, strlen(url), 0, 0, re_ovector, 30) >= 0 ) { … … 318 321 if (url[i] == ':') 319 322 { /* We found :<port>. Stop parse */ 320 break;321 323 } else { 322 324 DNS.url[count]=url[i]; … … 334 336 } 335 337 } 336 337 338 /** ÉÝÅÍ × ÓÐÉÓËÅ ÌÏËÁÌØÎÙÈ ÈÏÓÔÏ× **/ 338 339 /* ÐÏÌÕÞÁÅÍ ÄÏÍÅÎÎÏÅ ÉÍÑ*/
