Merge pull request #27532 from eplankin:warp_fix

Fixed memory leak in ipp_warp function
This commit is contained in:
Alexander Smorkalov 2025-07-14 08:54:44 +03:00 committed by GitHub
commit 824cbf51ec
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -251,6 +251,8 @@ public:
if( !IPPSet( cv::Scalar(borderValue[0], borderValue[1], borderValue[2], borderValue[3]), dataPointer, (int)dst.step[0], setSize, cnn, src.depth() ) ) if( !IPPSet( cv::Scalar(borderValue[0], borderValue[1], borderValue[2], borderValue[3]), dataPointer, (int)dst.step[0], setSize, cnn, src.depth() ) )
{ {
*ok = false; *ok = false;
ippsFree(pBuffer);
ippsFree(pSpec);
return; return;
} }
} }
@ -262,6 +264,8 @@ public:
{ {
CV_IMPL_ADD(CV_IMPL_IPP|CV_IMPL_MT); CV_IMPL_ADD(CV_IMPL_IPP|CV_IMPL_MT);
} }
ippsFree(pBuffer);
ippsFree(pSpec);
} }
private: private:
int src_type; int src_type;