The C++ 3 deep arrays were seg-faulting, since the initial vector
was not initialized correctly with the size. This patch ensures
that this happens correctly.
I've validated that the 3 deep array of Ints works correctly after
this patch.
Change-Id: I55166105d2a6a9ee97d88e287b54705a8f175cb6
Signed-off-by: Erich Keane <erich.keane@intel.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/2432
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Jon A. Cruz <jonc@osg.samsung.com>
}
else if (depth == 3)
{
- std::vector<std::vector<std::vector<T>>> val;
+ std::vector<std::vector<std::vector<T>>> val(pl->arr.dimensions[0]);
for(size_t i = 0; i < pl->arr.dimensions[0]; ++i)
{
val[i].resize(pl->arr.dimensions[1]);