Bladeren bron

Merge branch 'master' of ssh://git.sip-router.org/sip-router

Carsten Bock 13 jaren geleden
bovenliggende
commit
b197675136
5 gewijzigde bestanden met toevoegingen van 14 en 14 verwijderingen
  1. 3 3
      Makefile.defs
  2. 1 1
      action.c
  3. 1 1
      forward.c
  4. 1 1
      parser/msg_parser.c
  5. 8 8
      tcp_main.c

+ 3 - 3
Makefile.defs

@@ -935,9 +935,9 @@ ifeq		($(CC_NAME), clang)
 $(call                          set_if_empty,CPU,athlon64)
 					C_DEFS+=-DCC_GCC_LIKE_ASM
                                         CFLAGS+=-m32
+                                                -O9      \
                                                          \
-                                                         \
-                                                        -mtune=$(CPU)
+                                                -mtune=$(CPU)
                                         LDFLAGS+=-m32
 else			# CC_NAME, clang
 ifeq		($(CC_NAME), icc)
@@ -1031,7 +1031,7 @@ ifeq            ($(CC_NAME), clang)
 $(call                          set_if_empty,CPU,opteron)
 					C_DEFS+=-DCC_GCC_LIKE_ASM
                                         CFLAGS+=-m64 \
-                                                        
+                                                -O9        
                                         LDFLAGS+=-m64
 else      	# CC_NAME, clang
 ifeq		($(CC_NAME), icc)

+ 1 - 1
action.c

@@ -140,7 +140,7 @@ struct onsend_info* p_onsend=0; /* onsend route send info */
 				if ((dst)[i+2].type == RVE_FREE_FIXUP_ST) {\
 					/* call free_fixup (which should restore the original
 					   string) */ \
-					call_fixup((cmd)->free_fixup, &(dst)[i+2].u.data, i+1); \
+					(void)call_fixup((cmd)->free_fixup, &(dst)[i+2].u.data, i+1); \
 				} else if ((dst)[i+2].type == FPARAM_DYN_ST) {\
 					/* completely frees fparam and restore original string */\
 					fparam_free_restore(&(dst)[i+2].u.data); \

+ 1 - 1
forward.c

@@ -648,7 +648,7 @@ int forward_request(struct sip_msg* msg, str* dst, unsigned short port,
 		if (msg_send(send_info, buf, len)<0){
 			ret=ser_error=E_SEND;
 #ifdef USE_DST_BLACKLIST
-			dst_blacklist_add(BLST_ERR_SEND, send_info, msg);
+			(void)dst_blacklist_add(BLST_ERR_SEND, send_info, msg);
 #endif
 #ifdef USE_DNS_FAILOVER
 			continue; /* try another ip */

+ 1 - 1
parser/msg_parser.c

@@ -88,7 +88,7 @@ unsigned int global_req_flags = 0;
 char* get_hdr_field(char* const buf, char* const end, struct hdr_field* const hdr)
 {
 
-	char* tmp;
+	char *tmp = 0;
 	char *match;
 	struct via_body *vb;
 	struct cseq_body* cseq_b;

+ 8 - 8
tcp_main.c

@@ -709,7 +709,7 @@ inline static int _wbufq_add(struct  tcp_connection* c, const char* data,
 		if (q->first && TICKS_LT(q->wr_timeout, t)){
 			if (unlikely(c->state==S_CONN_CONNECT)){
 #ifdef USE_DST_BLACKLIST
-				dst_blacklist_su( BLST_ERR_CONNECT, c->rcv.proto,
+				(void)dst_blacklist_su( BLST_ERR_CONNECT, c->rcv.proto,
 										&c->rcv.src_su, &c->send_flags, 0);
 #endif /* USE_DST_BLACKLIST */
 				TCP_EV_CONNECT_TIMEOUT(0, TCP_LADDR(c), TCP_LPORT(c),
@@ -717,7 +717,7 @@ inline static int _wbufq_add(struct  tcp_connection* c, const char* data,
 				TCP_STATS_CONNECT_FAILED();
 			}else{
 #ifdef USE_DST_BLACKLIST
-				dst_blacklist_su( BLST_ERR_SEND, c->rcv.proto,
+				(void)dst_blacklist_su( BLST_ERR_SEND, c->rcv.proto,
 									&c->rcv.src_su, &c->send_flags, 0);
 #endif /* USE_DST_BLACKLIST */
 				TCP_EV_SEND_TIMEOUT(0, &c->rcv);
@@ -3433,7 +3433,7 @@ inline static int handle_tcp_child(struct tcp_child* tcp_c, int fd_i)
 					/* timeout */
 					if (unlikely(tcpconn->state==S_CONN_CONNECT)){
 #ifdef USE_DST_BLACKLIST
-						dst_blacklist_su( BLST_ERR_CONNECT,
+						(void)dst_blacklist_su( BLST_ERR_CONNECT,
 											tcpconn->rcv.proto,
 											&tcpconn->rcv.src_su,
 											&tcpconn->send_flags, 0);
@@ -3444,7 +3444,7 @@ inline static int handle_tcp_child(struct tcp_child* tcp_c, int fd_i)
 						TCP_STATS_CONNECT_FAILED();
 					}else{
 #ifdef USE_DST_BLACKLIST
-						dst_blacklist_su( BLST_ERR_SEND,
+						(void)dst_blacklist_su( BLST_ERR_SEND,
 											tcpconn->rcv.proto,
 											&tcpconn->rcv.src_su,
 											&tcpconn->send_flags, 0);
@@ -4222,7 +4222,7 @@ inline static int handle_tcpconn_ev(struct tcp_connection* tcpconn, short ev,
 			if (unlikely(ev & POLLERR)){
 				if (unlikely(tcpconn->state==S_CONN_CONNECT)){
 #ifdef USE_DST_BLACKLIST
-					dst_blacklist_su(BLST_ERR_CONNECT, tcpconn->rcv.proto,
+					(void)dst_blacklist_su(BLST_ERR_CONNECT, tcpconn->rcv.proto,
 										&tcpconn->rcv.src_su,
 										&tcpconn->send_flags, 0);
 #endif /* USE_DST_BLACKLIST */
@@ -4232,7 +4232,7 @@ inline static int handle_tcpconn_ev(struct tcp_connection* tcpconn, short ev,
 					TCP_STATS_CONNECT_FAILED();
 				}else{
 #ifdef USE_DST_BLACKLIST
-					dst_blacklist_su(BLST_ERR_SEND, tcpconn->rcv.proto,
+					(void)dst_blacklist_su(BLST_ERR_SEND, tcpconn->rcv.proto,
 										&tcpconn->rcv.src_su,
 										&tcpconn->send_flags, 0);
 #endif /* USE_DST_BLACKLIST */
@@ -4409,7 +4409,7 @@ static ticks_t tcpconn_main_timeout(ticks_t t, struct timer_ln* tl, void* data)
 	if (tcp_async && _wbufq_non_empty(c) && TICKS_GE(t, c->wbuf_q.wr_timeout)){
 		if (unlikely(c->state==S_CONN_CONNECT)){
 #ifdef USE_DST_BLACKLIST
-			dst_blacklist_su(BLST_ERR_CONNECT, c->rcv.proto, &c->rcv.src_su,
+			(void)dst_blacklist_su(BLST_ERR_CONNECT, c->rcv.proto, &c->rcv.src_su,
 								&c->send_flags, 0);
 #endif /* USE_DST_BLACKLIST */
 			TCP_EV_CONNECT_TIMEOUT(0, TCP_LADDR(c), TCP_LPORT(c), TCP_PSU(c),
@@ -4417,7 +4417,7 @@ static ticks_t tcpconn_main_timeout(ticks_t t, struct timer_ln* tl, void* data)
 			TCP_STATS_CONNECT_FAILED();
 		}else{
 #ifdef USE_DST_BLACKLIST
-			dst_blacklist_su(BLST_ERR_SEND, c->rcv.proto, &c->rcv.src_su,
+			(void)dst_blacklist_su(BLST_ERR_SEND, c->rcv.proto, &c->rcv.src_su,
 								&c->send_flags, 0);
 #endif /* USE_DST_BLACKLIST */
 			TCP_EV_SEND_TIMEOUT(0, &c->rcv);