# HG changeset patch # User serb # Date 1495070574 25200 # Node ID d3d2db0f234f30de5a06c5e17c2ff65a2c5a970a # Parent 592c141b1ca35dccd76abc5367558c51529f6b8f 8179990: Cleaner palette entry handling Reviewed-by: prr, mschoene, rhalade diff -r 592c141b1ca3 -r d3d2db0f234f src/java.desktop/windows/native/libawt/windows/awt_Palette.cpp --- a/src/java.desktop/windows/native/libawt/windows/awt_Palette.cpp Wed May 17 14:57:10 2017 -0700 +++ b/src/java.desktop/windows/native/libawt/windows/awt_Palette.cpp Wed May 17 18:22:54 2017 -0700 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2001, 2008, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2001, 2017, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -148,7 +148,7 @@ pEntry->peFlags = PC_EXPLICIT; } hPal = ::CreatePalette(pLogPal); - delete pLogPal; + delete[] pLogPal; if ( hPal == 0 ) { return 0; }