diff --git a/include/hack.hpp b/include/hack.hpp index e778cb11..31993cb6 100644 --- a/include/hack.hpp +++ b/include/hack.hpp @@ -23,7 +23,7 @@ namespace hack extern std::mutex command_stack_mutex; std::stack &command_stack(); -void ExecuteCommand(const std::string command); +void ExecuteCommand(const std::string &command); extern bool game_shutdown; extern bool shutdown; diff --git a/src/hack.cpp b/src/hack.cpp index da0a09b0..b192a912 100644 --- a/src/hack.cpp +++ b/src/hack.cpp @@ -94,7 +94,7 @@ std::stack &hack::command_stack() return stack; } -void hack::ExecuteCommand(const std::string command) +void hack::ExecuteCommand(const std::string &command) { std::lock_guard guard(hack::command_stack_mutex); hack::command_stack().push(command);