浏览代码

Remove unsent requests from the write queue when we receive a choke.

master
Richard Nyberg 19 年前
父节点
当前提交
93053ce34a
共有 1 个文件被更改,包括 7 次插入0 次删除
  1. +7
    -0
      btpd/peer.c

+ 7
- 0
btpd/peer.c 查看文件

@@ -335,6 +335,13 @@ peer_on_choke(struct peer *p)
else {
p->flags |= PF_P_CHOKE;
cm_on_choke(p);
struct nb_link *nl = BTPDQ_FIRST(&p->outq);
while (nl != NULL) {
struct nb_link *next = BTPDQ_NEXT(nl, entry);
if (nl->nb->type == NB_REQUEST)
peer_unsend(p, nl);
nl = next;
}
}
}



||||||
x
 
000:0
正在加载...
取消
保存