File tree 1 file changed +3
-5
lines changed
1 file changed +3
-5
lines changed Original file line number Diff line number Diff line change @@ -1300,12 +1300,10 @@ static MagickBooleanType GetPeakAbsoluteDistortion(const Image *image,
1300
1300
rows ;
1301
1301
1302
1302
ssize_t
1303
- i ,
1304
1303
y ;
1305
1304
1306
1305
status = MagickTrue ;
1307
- for (i = 0 ; i <= CompositeChannels ; i ++ )
1308
- distortion [i ]= MagickMinimumValue ;
1306
+ (void ) memset (distortion ,0 ,(CompositeChannels + 1 )* sizeof (* distortion ));
1309
1307
rows = MagickMax (image -> rows ,reconstruct_image -> rows );
1310
1308
columns = MagickMax (image -> columns ,reconstruct_image -> columns );
1311
1309
image_view = AcquireVirtualCacheView (image ,exception );
@@ -1342,8 +1340,8 @@ static MagickBooleanType GetPeakAbsoluteDistortion(const Image *image,
1342
1340
}
1343
1341
indexes = GetCacheViewVirtualIndexQueue (image_view );
1344
1342
reconstruct_indexes = GetCacheViewVirtualIndexQueue (reconstruct_view );
1345
- for ( i = 0 ; i <= CompositeChannels ; i ++ )
1346
- channel_distortion [ i ] = MagickMinimumValue ;
1343
+ ( void ) memset ( channel_distortion , 0 ,( CompositeChannels + 1 ) *
1344
+ sizeof ( * channel_distortion )) ;
1347
1345
for (x = 0 ; x < (ssize_t ) columns ; x ++ )
1348
1346
{
1349
1347
MagickRealType
You can’t perform that action at this time.
0 commit comments