Browse code

dlgs: proper return for tags counting

- GH #2884

(cherry picked from commit 1f12e2a03856f9c2d12cf62c1e65e84380729a06)
(cherry picked from commit b6484e4614ebc0f3fd54224ba9470d6c5b322a6f)

Daniel-Constantin Mierla authored on 14/10/2021 08:09:32
Showing 1 changed files
... ...
@@ -344,10 +344,7 @@ static int ki_dlgs_tags_count(sip_msg_t *msg, str *vtags)
344 344
 	int ret;
345 345
 
346 346
 	ret = dlgs_tags_count(msg, vtags);
347
-	if(ret<=0) {
348
-		return (ret-1);
349
-	}
350
-	return 1;
347
+	return (ret<=0)?(ret-1):ret;
351 348
 }
352 349
 
353 350
 /**