From: Steinar H. Gunderson Date: Fri, 21 Dec 2018 22:42:34 +0000 (+0100) Subject: Fix a leak in test code. X-Git-Tag: 1.8.1~50 X-Git-Url: https://git.sesse.net/?p=nageru;a=commitdiff_plain;h=4a2b75458cf7e5c341d12b476fe9f806c3f1e73c Fix a leak in test code. Found by Coverity Scan. --- diff --git a/futatabi/util.cpp b/futatabi/util.cpp index 061408d..99711a6 100644 --- a/futatabi/util.cpp +++ b/futatabi/util.cpp @@ -16,6 +16,7 @@ Flow read_flow(const char *filename) unique_ptr flow(new Vec2[width * height]); fread(flow.get(), width * height * sizeof(Vec2), 1, flowfp); + fclose(flowfp); Flow ret; ret.width = width;