Fix bug in ParameterDictionary::lookupSingle() error check

This commit is contained in:
Matt Pharr 2022-11-20 11:21:22 -08:00
parent 4437d22630
commit 7c8b9ffd7a

View file

@ -217,7 +217,7 @@ typename ParameterTypeTraits<PT>::ReturnType ParameterDictionary::lookupSingle(
// Issue error if an incorrect number of parameter values were provided
if (values.empty())
ErrorExit(&p->loc, "No values provided for parameter \"%s\".", name);
if (values.size() > traits::nPerItem)
if (values.size() != traits::nPerItem)
ErrorExit(&p->loc, "Expected %d values for parameter \"%s\".",
traits::nPerItem, name);