[sr-dev] git:master:6090f7d9: core: tcp read - set own handling for ECONNRESET

Daniel-Constantin Mierla miconda at gmail.com
Mon Jul 17 16:09:38 CEST 2017


Module: kamailio
Branch: master
Commit: 6090f7d9de0c71b25bd66c3525b25de7d02a5aa1
URL: https://github.com/kamailio/kamailio/commit/6090f7d9de0c71b25bd66c3525b25de7d02a5aa1

Author: Daniel-Constantin Mierla <miconda at gmail.com>
Committer: Daniel-Constantin Mierla <miconda at gmail.com>
Date: 2017-07-17T16:08:45+02:00

core: tcp read - set own handling for ECONNRESET

---

Modified: src/core/tcp_read.c

---

Diff:  https://github.com/kamailio/kamailio/commit/6090f7d9de0c71b25bd66c3525b25de7d02a5aa1.diff
Patch: https://github.com/kamailio/kamailio/commit/6090f7d9de0c71b25bd66c3525b25de7d02a5aa1.patch

---

diff --git a/src/core/tcp_read.c b/src/core/tcp_read.c
index 77c63449b6..db3707b39e 100644
--- a/src/core/tcp_read.c
+++ b/src/core/tcp_read.c
@@ -278,6 +278,12 @@ int tcp_read_data(int fd, struct tcp_connection *c,
 						switch(errno){
 							case ECONNRESET:
 								TCP_STATS_CON_RESET();
+#ifdef USE_DST_BLACKLIST
+								dst_blacklist_su(BLST_ERR_SEND, c->rcv.proto,
+													&c->rcv.src_su,
+													&c->send_flags, 0);
+#endif /* USE_DST_BLACKLIST */
+								break;
 							case ETIMEDOUT:
 #ifdef USE_DST_BLACKLIST
 								dst_blacklist_su(BLST_ERR_SEND, c->rcv.proto,




More information about the sr-dev mailing list