mirror of
https://github.com/JulianGro/overte.git
synced 2025-04-14 05:26:32 +02:00
Fix checked_at in OBJReader to use ref
This commit is contained in:
parent
d28b12ec3c
commit
62f1e8d129
1 changed files with 1 additions and 1 deletions
|
@ -35,7 +35,7 @@ const QString SMART_DEFAULT_MATERIAL_NAME = "High Fidelity smart default materia
|
|||
|
||||
namespace {
|
||||
template<class T>
|
||||
T& checked_at(QVector<T> vector, int i) {
|
||||
T& checked_at(QVector<T>& vector, int i) {
|
||||
if (i < 0 || i >= vector.size()) {
|
||||
throw std::out_of_range("index " + std::to_string(i) + "is out of range");
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue