mirror of https://github.com/ecmwf/eccodes.git
ECC-435: CRASH: Python keys iterator on GRIB message
This commit is contained in:
parent
74840461a7
commit
bdb3321519
|
@ -996,8 +996,9 @@ def grib_get_string_array(msgid, key):
|
|||
|
||||
GRIB_CHECK(_internal.grib_c_get_string_array(msgid, key, a, s))
|
||||
|
||||
newsize = s.value()
|
||||
result = list()
|
||||
for i in range(nval):
|
||||
for i in range(newsize):
|
||||
result.append(_internal.stringArray_getitem(a, i))
|
||||
|
||||
_internal.delete_stringArray(a)
|
||||
|
|
Loading…
Reference in New Issue