Memory leaks

This commit is contained in:
Shahram Najm 2020-06-30 15:06:53 +01:00
parent cbe37961b5
commit 3624d2218b
1 changed files with 4 additions and 8 deletions

View File

@ -8,11 +8,6 @@
* virtue of its status as an intergovernmental organisation nor does it submit to any jurisdiction.
*/
/*
* C Implementation: grib_tools
*
*/
#include "grib_tools.h"
#if HAVE_LIBJASPER
/* Remove compiler warnings re macros being redefined */
@ -567,9 +562,10 @@ static int grib_tool_index(grib_runtime_options* options)
}
navigate(options->index2->fields, options);
/* TODO(masn): memleak
* grib_context_free(c, options->index2->current);
*/
if (options->index2)
grib_context_free(c, options->index2->current);
grib_tool_finalise_action(options);
return 0;