From 7cb9b40b1d3001833cd7421a59906961d201dc81 Mon Sep 17 00:00:00 2001 From: Tommy Bojanin Date: Thu, 15 Jul 2021 21:36:18 -0700 Subject: [PATCH] dense: close file in reading invalid depth-map (#685) --- libs/MVS/DepthMap.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/libs/MVS/DepthMap.cpp b/libs/MVS/DepthMap.cpp index d90634fb9..06f3d0144 100644 --- a/libs/MVS/DepthMap.cpp +++ b/libs/MVS/DepthMap.cpp @@ -1844,6 +1844,7 @@ bool MVS::ImportDepthDataRaw(const String& fileName, String& imageFileName, header.imageWidth < header.depthWidth || header.imageHeight < header.depthHeight) { DEBUG("error: invalid depth-data file '%s'", fileName.c_str()); + fclose(f); return false; }