From 443059e371e379799a8ac72d8e87464d909b3464 Mon Sep 17 00:00:00 2001 From: Alexander Alekhin Date: Thu, 21 Dec 2017 01:10:24 +0000 Subject: [PATCH] imgcodecs(pxm): fix memcpy size 7bbe1a53cfc097b82b1589f7915a2120de39274c --- modules/highgui/src/grfmt_pxm.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/highgui/src/grfmt_pxm.cpp b/modules/highgui/src/grfmt_pxm.cpp index e609d16596..36f9a059e5 100644 --- a/modules/highgui/src/grfmt_pxm.cpp +++ b/modules/highgui/src/grfmt_pxm.cpp @@ -331,7 +331,7 @@ bool PxMDecoder::readData( Mat& img ) } } else - memcpy( data, src, m_width*(bit_depth/8) ); + memcpy(data, src, img.elemSize1()*m_width); } else {