mirror of https://github.com/ecmwf/eccodes.git
Fix memory leak
This commit is contained in:
parent
d0b4e1f0ea
commit
944a7838ee
|
@ -127,9 +127,11 @@ int grib_tool_new_handle_action(grib_runtime_options* options, grib_handle* h)
|
|||
|
||||
if (options->set_values_count != 0) {
|
||||
err = grib_set_values(h, options->set_values, options->set_values_count);
|
||||
if (err != GRIB_SUCCESS && options->fail)
|
||||
if (err != GRIB_SUCCESS && options->fail) {
|
||||
free(v);
|
||||
exit(err);
|
||||
}
|
||||
}
|
||||
|
||||
if (options->repack) {
|
||||
if (grib_options_on("d:")) {
|
||||
|
|
Loading…
Reference in New Issue