소스 검색

- minor tls typo fix

Andrei Pelinescu-Onciul 22 년 전
부모
커밋
faa66933d5
3개의 변경된 파일9개의 추가작업 그리고 8개의 파일을 삭제
  1. 5 1
      NEWS
  2. 0 5
      main.c
  3. 4 2
      tcp_main.c

+ 5 - 1
NEWS

@@ -11,7 +11,11 @@ texops:
  - subst('s/re/repl/flags') support
 core:
  - added switch to check the config file (-c)
- - changes: removed len_gt() and replaced with if (msg:len op number|max_len)
+ - changes: 
+       removed len_gt() and replaced with if (msg:len op number|max_len)
+       protocol and port can be specified in the alias and listen lines, e.g.:
+        alias= tcp:foo.bar:* udp:test.bar:5080 foo.com
+        listen= eth0   tcp:eth0:5065 udp:127.0.0.1 [3ffe::1]
  - multiple operator support: ==, != for special operations (e.g myself, ip)
                               ==, !=, ~= for strings
                               ==, !=, >, <, >=, <= for integers

+ 0 - 5
main.c

@@ -759,11 +759,6 @@ int main_loop()
 #ifdef USE_TCP
 	int sockfd[2];
 #endif
-#ifdef USE_TLS
-	char* tmp;
-	int len;
-#endif
-		
 
 	/* one "main" process and n children handling i/o */
 

+ 4 - 2
tcp_main.c

@@ -562,7 +562,7 @@ int tcp_init(struct socket_info* sock_info)
 #endif
 	
 	addr=&sock_info->su;
-	sock_info->proto=PROTO_TCP;
+	/* sock_info->proto=PROTO_TCP; */
 	if (init_su(addr, &sock_info->address, sock_info->port_no)<0){
 		LOG(L_ERR, "ERROR: tcp_init: could no init sockaddr_union\n");
 		goto error;
@@ -750,7 +750,9 @@ void tcp_main_loop()
 				FD_SET(si->socket, &master_set);
 				if (si->socket>maxfd) maxfd=si->socket;
 			}else{
-			LOG(L_CRIT, "BUG: tcp_main_loop: non tls address in tls_listen\n");
+				LOG(L_CRIT, "BUG: tcp_main_loop: non tls address"
+						" in tls_listen\n");
+			}
 		}
 	}
 #endif