Skip to content
Permalink
Browse files

8247464: Memory Leak in MTLBlitLoops_CopyArea() method

  • Loading branch information
Ajit Ghaisas
Ajit Ghaisas committed Jun 12, 2020
1 parent 12b63f5 commit 955a58a59bdb9717be5fa957945dafca99094004
Showing with 1 addition and 1 deletion.
  1. +1 −1 src/java.desktop/macosx/native/libawt_lwawt/java2d/metal/MTLBlitLoops.m
@@ -824,7 +824,7 @@ jboolean clipDestCoords(

// Create an intrermediate buffer
int totalBuffsize = width * height * 4;
id <MTLBuffer> buff = [mtlc.device newBufferWithLength:totalBuffsize options:MTLResourceStorageModePrivate];
id <MTLBuffer> buff = [[mtlc.device newBufferWithLength:totalBuffsize options:MTLResourceStorageModePrivate] autorelease];

[blitEncoder copyFromTexture:dstOps->pTexture
sourceSlice:0 sourceLevel:0 sourceOrigin:MTLOriginMake(x, y, 0) sourceSize:MTLSizeMake(width, height, 1)

0 comments on commit 955a58a

Please sign in to comment.
You can’t perform that action at this time.