git repos / blockattack-game

commit 7025bd6c

branches: v2.1.X

sago007 · 2017-04-01 18:27
7025bd6c00f76c6667abb023b27081243f025ad1 patch · browse files
parent 92923ac78986836b3f354892b6b0aefc501a4713

Hotfix for Issue #14

Changed files

M source/code/common.cpp before
diff --git a/source/code/common.cpp b/source/code/common.cpp index e4cf830..882aae6 100644 --- a/source/code/common.cpp +++ b/source/code/common.cpp
@@ -49,7 +49,7 @@ double str2double(const string& str2parse) {
try {
return std::stod(str2parse);
}
- catch (std::ios_base::failure& f) {
+ catch (...) {
return 0.0;
}
}
@@ -78,7 +78,7 @@ int str2int(const string& str2parse) {
try {
return std::stoi(str2parse);
}
- catch (std::ios_base::failure& f) {
+ catch (...) {
return 0;
}
}