瀏覽代碼

tm: TMCB_E2EACK callback fix

TMCB_E2EACK_RETR_IN was called instead of TMCB_E2EACK_IN
for the initial e2e-ACK message.
Miklos Tirpak 16 年之前
父節點
當前提交
3da5ebc8bd
共有 1 個文件被更改,包括 3 次插入3 次删除
  1. 3 3
      modules/tm/t_reply.c

+ 3 - 3
modules/tm/t_reply.c

@@ -271,9 +271,9 @@ int unmatched_totag(struct cell *t, struct sip_msg *ack)
 		if (i->tag.len==tag->len
 				&& memcmp(i->tag.s, tag->s, tag->len)==0) {
 			DBG("DEBUG: totag for e2e ACK found: %d\n", i->acked);
-			/* mark totag as acked and return 0 if this was the first ack
-			 * and 1 otherwise */
-			return atomic_get_and_set_int(&i->acked, 1);
+			/* mark totag as acked and return 1 if this was the first ack
+			 * and 0 otherwise */
+			return (atomic_get_and_set_int(&i->acked, 1)==0);
 		}
 		i=i->next;
 	}