bug fixed

pull/278/head
davide 9 years ago
parent 6d0f48763c
commit b1e2744599

@ -90,7 +90,8 @@ inline thread_pool::thread_pool(size_t num_threads,
// if the weak pointer points to a delated handle, remove it // if the weak pointer points to a delated handle, remove it
if(!handle ){ if(!handle ){
_loop_handles.erase(handle_it); _loop_handles.erase(handle_it);
_index = (_index) % _loop_handles.size(); if( _loop_handles.empty() ==false)
_index = (_index) % _loop_handles.size();
} }
else{ else{
// mark as busy // mark as busy

Loading…
Cancel
Save