From d06e1359438233d2d6ab002b75c89f24c5e4ebbd Mon Sep 17 00:00:00 2001 From: Alec Woods Date: Sun, 1 Nov 2020 11:14:34 -0500 Subject: [PATCH] Avoid double free in boxFilterNPP.cpp The device memory for the image will be automatically freed when the image object itself is destroyed. --- Samples/boxFilterNPP/boxFilterNPP.cpp | 3 --- 1 file changed, 3 deletions(-) diff --git a/Samples/boxFilterNPP/boxFilterNPP.cpp b/Samples/boxFilterNPP/boxFilterNPP.cpp index f3ce90ed..277819d1 100644 --- a/Samples/boxFilterNPP/boxFilterNPP.cpp +++ b/Samples/boxFilterNPP/boxFilterNPP.cpp @@ -167,9 +167,6 @@ int main(int argc, char *argv[]) { saveImage(sResultFilename, oHostDst); std::cout << "Saved image: " << sResultFilename << std::endl; - nppiFree(oDeviceSrc.data()); - nppiFree(oDeviceDst.data()); - exit(EXIT_SUCCESS); } catch (npp::Exception &rException) { std::cerr << "Program error! The following exception occurred: \n";