United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
Bug ID: JDK-7124400 [macosx] CGraphicsDevice.getConfigurations() returns reference to member (does not copy configs)
JDK-7124400 : [macosx] CGraphicsDevice.getConfigurations() returns reference to member (does not copy configs)

Details
Type:
Bug
Submit Date:
2011-12-23
Status:
Closed
Updated Date:
2012-06-20
Project Name:
JDK
Resolved Date:
2012-06-20
Component:
client-libs
OS:
os_x
Sub-Component:
2d
CPU:
generic
Priority:
P3
Resolution:
Fixed
Affected Versions:
7
Fixed Versions:
7u6 (b13)

Related Reports
Backport:

Sub Tasks

Description
http://java.net/jira/browse/MACOSX_PORT-244 submitted 2011/08/08 by Taras Ledkov
Target build: b202
Keywords: test-fail-macos
Test (regression):
java/awt/GraphicsDevice/CloneConfigsTest.java
Test verifies that list of supported graphics configurations can not be changed via modification of elements of an array returned by getConfiguration() method.
But it waits GraphicsConfiguration[] instead of CGraphicsConfig[].
Also it waits, that changes into retrieved array have not affect on GraphicsDevice (it seems to me).
Please see src/macosx/classes/sun/awt/CGraphicsDevice.java (lines: 43, 69)
Test passed on JDK6

                                    

Comments
EVALUATION

Author: Taras Ledkov Date: 20/Sep/11 01:24 PM
Please take a look at suggested hot fix in attachment (<span class=&quot;nobr&quot;><a href=&quot;/jira/secure/attachment/47304/47304_MACOSX_PORT-244.diff&quot; title=&quot;MACOSX_PORT-244.diff attached to MACOSX_PORT-244&quot;>MACOSX_PORT-244.diff<sup><img class=&quot;rendericon&quot; src=&quot;/jira/images/icons/link_attachment_7.gif&quot; height=&quot;7&quot; width=&quot;7&quot; align=&quot;absmiddle&quot; alt=&quot;&quot; border=&quot;0&quot;/></sup></a></span>).
 
Author: Mike Swingler Date: 21/Sep/11 06:48 AM
Looks fine to me.
                                     
2011-12-23
SUGGESTED FIX

http://cr.openjdk.java.net/~bae/7124400/7u6/webrev.00/
                                     
2012-05-25



Hardware and Software, Engineered to Work Together