merged connection_queue patch from RC_0_16
This commit is contained in:
parent
27db5e3f49
commit
70740a0ecd
|
@ -80,18 +80,15 @@ namespace libtorrent
|
|||
|
||||
entry* e = 0;
|
||||
|
||||
switch (priority)
|
||||
if (priority <= 0)
|
||||
{
|
||||
case 0:
|
||||
m_queue.push_back(entry());
|
||||
e = &m_queue.back();
|
||||
break;
|
||||
case 1:
|
||||
case 2:
|
||||
m_queue.push_front(entry());
|
||||
e = &m_queue.front();
|
||||
break;
|
||||
default: return;
|
||||
m_queue.push_back(entry());
|
||||
e = &m_queue.back();
|
||||
}
|
||||
else // priority > 0
|
||||
{
|
||||
m_queue.push_front(entry());
|
||||
e = &m_queue.front();
|
||||
}
|
||||
|
||||
e->priority = priority;
|
||||
|
|
Loading…
Reference in New Issue