summaryrefslogtreecommitdiff
path: root/src/command_manager.cc
diff options
context:
space:
mode:
authorMaxime Coste <frrrwww@gmail.com>2011-09-09 18:40:59 +0000
committerMaxime Coste <frrrwww@gmail.com>2011-09-09 18:40:59 +0000
commit3caf96211085254ab3c42a59ce2c80a4ade3d2d8 (patch)
treec795d6e6b39f8f9bbf4422ede5d1bc20fd277f4b /src/command_manager.cc
parent0676eaec5cc56bf14b7791f5a2ef5485a7a43370 (diff)
exception: refactoring
Diffstat (limited to 'src/command_manager.cc')
-rw-r--r--src/command_manager.cc6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/command_manager.cc b/src/command_manager.cc
index aa1237d5..0cf2cff9 100644
--- a/src/command_manager.cc
+++ b/src/command_manager.cc
@@ -37,10 +37,10 @@ static std::vector<std::string> split(const std::string& line)
return result;
}
-struct command_not_found : public std::runtime_error
+struct command_not_found : runtime_error
{
- command_not_found(const std::string& what)
- : std::runtime_error("command not found: " + what) {}
+ command_not_found(const std::string& command)
+ : runtime_error(command + " : no such command") {}
};
void CommandManager::execute(const std::string& command_line)