summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPetr Mrázek <peterix@gmail.com>2018-05-20 01:53:05 +0200
committerPetr Mrázek <peterix@gmail.com>2018-05-20 01:53:05 +0200
commitf0ff2db4e1a81bc941ea8b6ce43f7fb63d34547a (patch)
tree9d3f1326800ee48a65a4cbe24dfcd5e78adbf9c9
parent72c0002b45215466e06cd901fe95d9493d659ab2 (diff)
downloadMultiMC-f0ff2db4e1a81bc941ea8b6ce43f7fb63d34547a.tar
MultiMC-f0ff2db4e1a81bc941ea8b6ce43f7fb63d34547a.tar.gz
MultiMC-f0ff2db4e1a81bc941ea8b6ce43f7fb63d34547a.tar.lz
MultiMC-f0ff2db4e1a81bc941ea8b6ce43f7fb63d34547a.tar.xz
MultiMC-f0ff2db4e1a81bc941ea8b6ce43f7fb63d34547a.zip
GH-2277 fix even more exception catches by value
-rw-r--r--api/logic/Json.h2
-rw-r--r--libraries/classparser/src/classparser.cpp2
2 files changed, 2 insertions, 2 deletions
diff --git a/api/logic/Json.h b/api/logic/Json.h
index 321007cd..a84d204a 100644
--- a/api/logic/Json.h
+++ b/api/logic/Json.h
@@ -123,7 +123,7 @@ T ensureIsType(const QJsonValue &value, const T default_ = T(), const QString &w
{
return requireIsType<T>(value, what);
}
- catch (JsonException)
+ catch (const JsonException &)
{
return default_;
}
diff --git a/libraries/classparser/src/classparser.cpp b/libraries/classparser/src/classparser.cpp
index bf5cc039..6587a2b9 100644
--- a/libraries/classparser/src/classparser.cpp
+++ b/libraries/classparser/src/classparser.cpp
@@ -70,7 +70,7 @@ QString GetMinecraftJarVersion(QString jarName)
}
}
}
- catch (java::classfile_exception) { }
+ catch (const java::classfile_exception &) { }
// clean up
delete[] classfile;