瀏覽代碼

usrloc: remove the filter on nat_bflag for keepalive contact expiration

- keepalives can be sent even for non-natted contacts
- reported by Kristian Kielhofner
Daniel-Constantin Mierla 11 年之前
父節點
當前提交
aa2ee6e1d9
共有 1 個文件被更改,包括 1 次插入2 次删除
  1. 1 2
      modules/usrloc/dlist.c

+ 1 - 2
modules/usrloc/dlist.c

@@ -342,8 +342,7 @@ static inline int get_all_mem_ucontacts(void *buf, int len, unsigned int flags,
 
 					if(ul_keepalive_timeout>0 && c->last_keepalive>0)
 					{
-						if((c->cflags & nat_bflag) != 0 && c->sock!=NULL
-								&& c->sock->proto==PROTO_UDP)
+						if(c->sock!=NULL && c->sock->proto==PROTO_UDP)
 						{
 							if(c->last_keepalive+ul_keepalive_timeout < tnow)
 							{