Tests: Fix memory leaks

This commit is contained in:
Shahram Najm 2020-02-10 10:58:53 +00:00
parent a1bc355249
commit f626d05184
2 changed files with 2 additions and 0 deletions

View File

@ -1463,6 +1463,7 @@ grib_handle* grib_util_set_spec2(grib_handle* h,
default:
fprintf(stderr, "invalid packing_spec->accuracy = %ld\n", (long)packing_spec->accuracy);
grib_handle_delete(tmp);
*err = GRIB_INTERNAL_ERROR;
goto cleanup;
break;

View File

@ -242,6 +242,7 @@ static void test_regular_ll(int remove_local_def, int edition, const char* packi
}
codes_handle_delete(handle);
codes_handle_delete(finalh);
free(values);
fclose(in);
fclose(out);
}