Declare valueString before passing to ParseScalar

This is to account for the length of the scalar string value, which is passed as
an element of event.data.scalar.
This commit is contained in:
Eryn Wells 2014-07-19 11:40:02 -07:00
parent 693e4fa80d
commit 98fe95e1a5

View file

@ -61,7 +61,9 @@ struct VectorParser
}
Type value;
if (!ParseScalar<Type>((const char *)event.data.scalar.value, value)) {
std::string valueString((char*)event.data.scalar.value,
event.data.scalar.length);
if (!ParseScalar<Type>(valueString, value)) {
assert(false);
}
mVector.push_back(value);