hedgewars/uLandObjects.pas
changeset 15373 410a83aa9d9a
parent 15372 3907c95227b8
child 15382 34eb5cc72241
--- a/hedgewars/uLandObjects.pas	Fri Aug 23 21:04:40 2019 +0300
+++ b/hedgewars/uLandObjects.pas	Fri Aug 23 21:12:56 2019 +0300
@@ -348,7 +348,7 @@
 
 procedure ChecksumLandObjectImage(Image: PSDL_Surface; alphaOnly: boolean);
 var y, x: LongInt;
-var rowData: PByte;
+var rowData: PByteArray;
 begin
     if Image = nil then exit;
 
@@ -369,7 +369,7 @@
         if alphaOnly then
             begin
             for x := 0 to Image^.w - 1 do
-                PByteArray(rowData)^[x] := PByteArray(Image^.pixels)^[y * Image^.pitch + x * 4 + AByteIndex];
+                rowData^[x] := PByteArray(Image^.pixels)^[y * Image^.pitch + x * 4 + AByteIndex];
             syncedPixelDigest:= Adler32Update(syncedPixelDigest, rowData, Image^.w);
             end
         else