Complain about given arguments if none are required.

This commit is contained in:
Florian Pose
2009-03-19 08:43:05 +00:00
parent 5f7cd5eb46
commit 87cedad13f
10 changed files with 58 additions and 0 deletions
+6
View File
@@ -56,6 +56,12 @@ string CommandVersion::helpString() const
void CommandVersion::execute(MasterDevice &m, const StringVector &args)
{
if (args.size()) {
stringstream err;
err << "'" << getName() << "' takes no arguments!";
throwInvalidUsageException(err);
}
cout << "IgH EtherCAT master " << EC_MASTER_VERSION << endl;
}