Module: kamailio
Branch: master
Commit: 15403a543d83e337ee578ad37dc1d84316e4cf16
URL:
https://github.com/kamailio/kamailio/commit/15403a543d83e337ee578ad37dc1d84…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2024-06-12T16:21:34+02:00
core: tcp - change log levels for failing to set source for tcp connections
- it is not possible always and it can fill the logs
---
Modified: src/core/tcp_main.c
---
Diff:
https://github.com/kamailio/kamailio/commit/15403a543d83e337ee578ad37dc1d84…
Patch:
https://github.com/kamailio/kamailio/commit/15403a543d83e337ee578ad37dc1d84…
---
diff --git a/src/core/tcp_main.c b/src/core/tcp_main.c
index 2456459cfa2..d5a46030cf4 100644
--- a/src/core/tcp_main.c
+++ b/src/core/tcp_main.c
@@ -1288,7 +1288,7 @@ inline static int find_listening_sock_info(
if(setsockopt(s, SOL_SOCKET, SO_REUSEADDR, (void *)&optval,
sizeof(optval))
== -1) {
- LM_ERR("setsockopt SO_REUSEADDR %s\n", strerror(errno));
+ LM_NOTICE("setsockopt SO_REUSEADDR [%s]\n", strerror(errno));
/* continue, not critical */
}
#endif
@@ -1297,19 +1297,19 @@ inline static int find_listening_sock_info(
if(setsockopt(s, SOL_SOCKET, SO_REUSEPORT, (void *)&optval,
sizeof(optval))
== -1) {
- LM_ERR("setsockopt SO_REUSEPORT %s\n", strerror(errno));
+ LM_NOTICE("setsockopt SO_REUSEPORT [%s]\n", strerror(errno));
/* continue, not critical */
}
#endif
if(unlikely(bind(s, &si->su.s, sockaddru_len(si->su)) != 0)) {
- LM_WARN("binding to source address %s failed: %s [%d]\n",
+ LM_DBG("binding to source address %s failed: [%s] [%d]\n",
su2a(&si->su, sizeof(si->su)), strerror(errno), errno);
return -1;
}
}
} else {
if(unlikely(bind(s, &(*from)->s, sockaddru_len(**from)) != 0)) {
- LM_WARN("binding to source address %s failed: %s [%d]\n",
+ LM_DBG("binding to source address %s failed: [%s] [%d]\n",
su2a(&si->su, sizeof(si->su)), strerror(errno), errno);
return -1;
}