[sr-dev] git:5.5:ede5a839: core: parser sdp - shorten debug message with sdp line

Daniel-Constantin Mierla miconda at gmail.com
Fri Aug 20 10:01:13 CEST 2021


Module: kamailio
Branch: 5.5
Commit: ede5a8399662903c2aa081b7010603398a598e94
URL: https://github.com/kamailio/kamailio/commit/ede5a8399662903c2aa081b7010603398a598e94

Author: Daniel-Constantin Mierla <miconda at gmail.com>
Committer: Daniel-Constantin Mierla <miconda at gmail.com>
Date: 2021-08-19T21:29:51+02:00

core: parser sdp - shorten debug message with sdp line

- was printing the rest of the body, print now max 20 chars

(cherry picked from commit 4191a8193025499df64f13d59f5716563e573161)

---

Modified: src/core/parser/sdp/sdp.c

---

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

---

diff --git a/src/core/parser/sdp/sdp.c b/src/core/parser/sdp/sdp.c
index 7dbf259379..d5e4f0695b 100644
--- a/src/core/parser/sdp/sdp.c
+++ b/src/core/parser/sdp/sdp.c
@@ -584,7 +584,8 @@ static int parse_sdp_session(str *sdp_body, int session_num, str *cnt_disp, sdp_
 				a1p = stream->path.s + stream->path.len;
 			} else {
 				/* unknown a= line, ignore -- jump over it */
-				LM_DBG("ignoring unknown type in a= line: `%.*s'\n", tmpstr1.len, tmpstr1.s);
+				LM_DBG("ignoring unknown type in a= line: `%.*s...'\n",
+						(tmpstr1.len>20)?20:tmpstr1.len, tmpstr1.s);
 				a1p += 2;
 			}
 




More information about the sr-dev mailing list