Explorar o código

Fixed a too big alloc in pixmap.

Mark Sibly %!s(int64=9) %!d(string=hai) anos
pai
achega
d0974cf061
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      modules/std/graphics/pixmap.monkey2

+ 1 - 1
modules/std/graphics/pixmap.monkey2

@@ -27,7 +27,7 @@ Class Pixmap
 
 		Local depth:=PixelFormatDepth( format )
 		Local pitch:=width*depth
-		Local data:=Cast<UByte Ptr>( libc.malloc( width*height*pitch ) )
+		Local data:=Cast<UByte Ptr>( libc.malloc( pitch*height ) )
 		
 		_width=width
 		_height=height