| 675 | //----------------------------------------------------------------------------- |
| 676 | |
| 677 | void stopServerQuery() |
| 678 | { |
| 679 | // Cancel the current query, anything left on the ping |
| 680 | // list is moved to the finished list as "done". |
| 681 | if ( sgServerQueryActive ) |
| 682 | { |
| 683 | gPacketStatusList.clear(); |
| 684 | |
| 685 | if ( gPingList.size() ) |
| 686 | { |
| 687 | while ( gPingList.size() ) |
| 688 | { |
| 689 | gFinishedList.push_back( gPingList[0].address ); |
| 690 | gPingList.erase( U32( 0 ) ); |
| 691 | } |
| 692 | } |
| 693 | else |
| 694 | cancelServerQuery(); |
| 695 | } |
| 696 | } |
| 697 | |
| 698 | DefineConsoleFunction( stopServerQuery, void, (), , "stopServerQuery();" ) |
| 699 | { |
no test coverage detected