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