Permalink
Browse files

Add a missing const to a method prototype in option_parser

  • Loading branch information...
1 parent a1f35de commit 38884ff5ba4410cd358c432e5fc925659feceeba @delroth delroth committed Apr 29, 2011
Showing with 5 additions and 4 deletions.
  1. +3 −3 src/option-parser.cc
  2. +2 −1 src/option-parser.hh
View
@@ -41,13 +41,13 @@ void option_parser::parse(int argc, const char** argv)
_cmd.push_back(argv[i]);
}
-void option_parser::print_usage(std::string prog, size_t ret,
- std::ostream& out) const
+void option_parser::print_usage(const std::string& prog, size_t ret,
+ std::ostream& out) const
{
out << "Usage: " << prog << " <memory> <time> <bin> [args...]"
<< std::endl
<< "Execute the program BIN in a jail with MEMORY ko and TIME ms."
- << "" << std::endl;
+ << std::endl;
exit(ret);
}
View
@@ -16,7 +16,8 @@ public:
size_t get_time() const;
protected:
- void print_usage(std::string prog, size_t ret, std::ostream& out) const;
+ void print_usage(const std::string& prog, size_t ret,
+ std::ostream& out) const;
cmd_type _cmd;
size_t _memory;

0 comments on commit 38884ff

Please sign in to comment.