diff options
author | Stijn Buys <ingar@osirion.org> | 2010-03-06 16:31:21 +0000 |
---|---|---|
committer | Stijn Buys <ingar@osirion.org> | 2010-03-06 16:31:21 +0000 |
commit | 6694c79aedea3f5989dd3befdafb7906557f155d (patch) | |
tree | 020b72f6fcc6cb14d698b72c1be58b1f04dea5ce /src/game | |
parent | 11a5ebe38a83383970425baf53d4595ae56efe70 (diff) |
fixes 'buy ship' without argument lock-up
Diffstat (limited to 'src/game')
-rw-r--r-- | src/game/base/shipdealer.cc | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/game/base/shipdealer.cc b/src/game/base/shipdealer.cc index d825e2c..adb97ea 100644 --- a/src/game/base/shipdealer.cc +++ b/src/game/base/shipdealer.cc @@ -86,14 +86,13 @@ void ShipDealer::func_buy(core::Player *player, const std::string &args) // enable rcon buffering sys::ConsoleInterface::instance()->set_rcon(true); ShipModel::list(); - + // disable rcon buffering + sys::ConsoleInterface::instance()->set_rcon(false); + while (sys::ConsoleInterface::instance()->rconbuf().size()) { player->send((*sys::ConsoleInterface::instance()->rconbuf().begin())); sys::ConsoleInterface::instance()->rconbuf().pop_front(); } - - // disable rcon buffering - sys::ConsoleInterface::instance()->set_rcon(false); player->send("Usage: buy ship label"); return; |