Fixed bug where the first registered forward would be automatically unregistered on unregisterForward too

This commit is contained in:
Pavol Marko 2004-09-09 20:32:34 +00:00
parent 66da3375ba
commit e378c45be7

View File

@ -397,13 +397,11 @@ bool CForwardMngr::isSPForward(int id) const
void CForwardMngr::unregisterSPForward(int id) void CForwardMngr::unregisterSPForward(int id)
{ {
unsigned int i = 0;
//make sure the id is valid //make sure the id is valid
if ( !isIdValid(id) || m_SPForwards.at(i >> 1)->isFree ) if ( !isIdValid(id) || m_SPForwards.at(id >> 1)->isFree )
return; return;
m_SPForwards.at(i >> 1)->isFree = true; m_SPForwards.at(id >> 1)->isFree = true;
m_FreeSPForwards.push(id); m_FreeSPForwards.push(id);
} }