From 57f1af3b8ba0d6646d2096bd5a298bd8d38d71ac Mon Sep 17 00:00:00 2001 From: Siju Date: Wed, 3 Jul 2019 10:14:29 +0530 Subject: [PATCH] [LITE]Fix array leak during resize o/p --- tensorflow/lite/kernels/fill.cc | 1 + 1 file changed, 1 insertion(+) diff --git a/tensorflow/lite/kernels/fill.cc b/tensorflow/lite/kernels/fill.cc index 079ee44f371..afd0c326ccc 100644 --- a/tensorflow/lite/kernels/fill.cc +++ b/tensorflow/lite/kernels/fill.cc @@ -38,6 +38,7 @@ TfLiteStatus ResizeOutputImpl(TfLiteContext* context, const TfLiteTensor* dims, for (int i = 0; i < output_shape->size; ++i) { T data = GetTensorData(dims)[i]; if (data < 0) { + TfLiteIntArrayFree(output_shape); context->ReportError(context, "Fill dimensions must be >= 0", dims->type); return kTfLiteError; }