Module: kamailio
Branch: 5.5
Commit: b6484e4614ebc0f3fd54224ba9470d6c5b322a6f
URL:
https://github.com/kamailio/kamailio/commit/b6484e4614ebc0f3fd54224ba9470d6…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2021-10-14T10:35:32+02:00
dlgs: proper return for tags counting
- GH #2884
(cherry picked from commit 1f12e2a03856f9c2d12cf62c1e65e84380729a06)
---
Modified: src/modules/dlgs/dlgs_mod.c
---
Diff:
https://github.com/kamailio/kamailio/commit/b6484e4614ebc0f3fd54224ba9470d6…
Patch:
https://github.com/kamailio/kamailio/commit/b6484e4614ebc0f3fd54224ba9470d6…
---
diff --git a/src/modules/dlgs/dlgs_mod.c b/src/modules/dlgs/dlgs_mod.c
index 503dd8c197..46de9d5c44 100644
--- a/src/modules/dlgs/dlgs_mod.c
+++ b/src/modules/dlgs/dlgs_mod.c
@@ -344,10 +344,7 @@ static int ki_dlgs_tags_count(sip_msg_t *msg, str *vtags)
int ret;
ret = dlgs_tags_count(msg, vtags);
- if(ret<=0) {
- return (ret-1);
- }
- return 1;
+ return (ret<=0)?(ret-1):ret;
}
/**