diff --git a/lib/jkqtcommon/jkqtpbasicimagetools.h b/lib/jkqtcommon/jkqtpbasicimagetools.h index 6417e75dfe..9911d2831c 100644 --- a/lib/jkqtcommon/jkqtpbasicimagetools.h +++ b/lib/jkqtcommon/jkqtpbasicimagetools.h @@ -657,7 +657,7 @@ inline void JKQTPImagePlot_array2RGBimage(const T* dbl_in, int width, int height T* dbllog=nullptr; if (logScale) { double logB=log10(logBase); - dbllog=static_cast(malloc(width*height*sizeof(T))); + dbllog=static_cast(malloc(static_cast(width)*static_cast(height)*sizeof(T))); //memcpy(dbl, dbl_in, width*height*sizeof(T)); for (int i=0; i0) { - colChecksum=static_cast(qChecksum(reinterpret_cast(data), Nx*Ny* getSampleSize()/sizeof(char))); + colChecksum=static_cast(qChecksum(reinterpret_cast(data), static_cast(Nx)*static_cast(Ny)* static_cast(getSampleSize()/sizeof(char)))); } /*if (parent && parent->getDatastore() && imageColumn>=0) { colChecksum=static_cast(parent->getDatastore()->getColumnChecksum(imageColumn));