Merge pull request #21963 from hellodoge:imwrite_fix

This commit is contained in:
OpenCV Pushbot 2022-05-12 09:02:54 +00:00 committed by GitHub
commit 9712cc479b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -602,9 +602,9 @@ bool JpegEncoder::write( const Mat& img, const std::vector<int>& params )
JpegErrorMgr jerr;
JpegDestination dest;
jpeg_create_compress(&cinfo);
cinfo.err = jpeg_std_error(&jerr.pub);
jerr.pub.error_exit = error_exit;
jpeg_create_compress(&cinfo);
if( !m_buf )
{