Avoid double free in cannyEdgeDetectorNPP.cpp

The device memory for the image will be automatically freed when the image object itself is destroyed.
This commit is contained in:
Alec Woods 2020-11-01 11:15:12 -05:00 committed by GitHub
parent d06e135943
commit 1f571da4f5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -208,9 +208,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";