| 534 | } |
| 535 | |
| 536 | void concurrent_queue_base_v3::internal_finish_clear() { |
| 537 | size_t nq = my_rep->n_queue; |
| 538 | for( size_t i=0; i<nq; ++i ) { |
| 539 | page* tp = my_rep->array[i].tail_page; |
| 540 | __TBB_ASSERT( my_rep->array[i].head_page==tp, "at most one page should remain" ); |
| 541 | if( tp!=NULL) { |
| 542 | if( tp!=invalid_page ) deallocate_page( tp ); |
| 543 | my_rep->array[i].tail_page = NULL; |
| 544 | } |
| 545 | } |
| 546 | } |
| 547 | |
| 548 | void concurrent_queue_base_v3::internal_throw_exception() const { |
| 549 | throw_exception( eid_bad_alloc ); |