[Scummvm-git-logs] scummvm branch-2-7 -> 863265c73433eab29fff88106583b34a48eb19b8

criezy noreply at scummvm.org
Mon Mar 27 00:31:50 UTC 2023


This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
863265c734 AGS: Fix double-free of room cameras surfaces


Commit: 863265c73433eab29fff88106583b34a48eb19b8
    https://github.com/scummvm/scummvm/commit/863265c73433eab29fff88106583b34a48eb19b8
Author: Thierry Crozat (criezy at scummvm.org)
Date: 2023-03-27T01:29:23+01:00

Commit Message:
AGS: Fix double-free of room cameras surfaces

This fixes a crash in Dreams in a Witch House (bug #14338)

Changed paths:
    engines/ags/engine/gfx/ali_3d_scummvm.cpp


diff --git a/engines/ags/engine/gfx/ali_3d_scummvm.cpp b/engines/ags/engine/gfx/ali_3d_scummvm.cpp
index 8686d75e117..07877a035b0 100644
--- a/engines/ags/engine/gfx/ali_3d_scummvm.cpp
+++ b/engines/ags/engine/gfx/ali_3d_scummvm.cpp
@@ -271,7 +271,7 @@ void ScummVMRendererGraphicsDriver::InitSpriteBatch(size_t index, const SpriteBa
 	const int src_h = desc.Viewport.GetHeight() / desc.Transform.ScaleY;
 	// Surface was prepared externally (common for room cameras)
 	if (desc.Surface != nullptr) {
-		batch.Surface = std::static_pointer_cast<Bitmap>(desc.Surface);
+		batch.Surface = desc.Surface;
 		batch.Opaque = true;
 		batch.IsVirtualScreen = false;
 	}




More information about the Scummvm-git-logs mailing list