[Performance] Change to use Pass by reference where valid. (#3163)

* [Performance] Change to use Pass by reference where valid.

* typo
This commit is contained in:
Aeadoin
2023-04-01 22:55:40 -04:00
committed by GitHub
parent 7f7ba2e6c2
commit 1ffdd4cb34
31 changed files with 66 additions and 66 deletions
+3 -3
View File
@@ -98,7 +98,7 @@ void Embperl::DoInit() {
try {
init_eval_file();
}
catch(std::string e)
catch(std::string& e)
{
//remember... lasterr() is no good if we crap out here, in construction
LogQuests("Perl Error [{}]", e);
@@ -138,7 +138,7 @@ void Embperl::DoInit() {
perl_command = "main::eval_file('plugin', '" + Config->PluginPlFile + "');";
eval_pv(perl_command.c_str(), FALSE);
}
catch(std::string e)
catch(std::string& e)
{
LogQuests("Warning [{}]: [{}]", Config->PluginPlFile, e);
}
@@ -156,7 +156,7 @@ void Embperl::DoInit() {
"}";
eval_pv(perl_command.c_str(),FALSE);
}
catch(std::string e)
catch(std::string& e)
{
LogQuests("Warning [{}]", e);
}