LCL-GTK3: Prevent a crash when starting the IDE build for GTK3.

git-svn-id: trunk@62259 -
This commit is contained in:
juha 2019-11-17 14:30:44 +00:00
parent 8d9ae58846
commit b5c25f2a0f

View File

@ -230,7 +230,8 @@ begin
ImageFormat := CAIRO_FORMAT_ARGB32;
end;
ARowStride := GetBytesPerLine(Desc.Width, Desc.BitsPerPixel, rileDWordBoundary);
ABitmap := HBitmap(TGtk3Image.Create(NewData, Desc.Width, Desc.Height, ARowStride, ImageFormat, True));
ABitmap := HBitmap(TGtk3Image.Create(NewData, Desc.Width, Desc.Height, ARowStride, ImageFormat,
not ASkipMask)); // Using ASkipMask for DataOwner param prevents a crash later.
Result := ABitmap <> 0;
if ASkipMask then Exit;