ECC-1172: BUFR encoding memory leaks (part 6)

This commit is contained in:
Shahram Najm 2022-11-08 17:51:00 +00:00
parent 43558f126e
commit bee6669f43
1 changed files with 3 additions and 1 deletions

View File

@ -2949,8 +2949,10 @@ static int process_elements(grib_accessor* a, int flag, long onlySubset, long st
self->numericValues = grib_vdarray_new(c, 1000, 1000);
self->stringValues = grib_vsarray_new(c, 10, 10);
if (self->elementsDescriptorsIndex)
if (self->elementsDescriptorsIndex) {
grib_viarray_delete_content(c, self->elementsDescriptorsIndex);
grib_viarray_delete(c, self->elementsDescriptorsIndex);
}
self->elementsDescriptorsIndex = grib_viarray_new(c, 100, 100);
}
if (flag == PROCESS_NEW_DATA) {