# HG changeset patch # User coffeys # Date 1332766900 -3600 # Node ID 5222b7d658d44317f2ae684b767c6f2d59fb08c0 # Parent 66c7161ee5883148ce788822f5c4ff59e08ee1a7 7143851: Improve IIOP stub and tie generation in RMIC 7149048: Changes to corba rmic stubGenerator class are not used during jdk build process Reviewed-by: mschoene, robm diff -r 66c7161ee588 -r 5222b7d658d4 src/share/classes/sun/rmi/rmic/iiop/StubGenerator.java --- a/src/share/classes/sun/rmi/rmic/iiop/StubGenerator.java Thu Nov 17 10:51:17 2011 -0800 +++ b/src/share/classes/sun/rmi/rmic/iiop/StubGenerator.java Mon Mar 26 14:01:40 2012 +0100 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998, 2007, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1998, 2012, 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 @@ -425,7 +425,7 @@ // Write the _ids() method... p.plnI("public String[] _ids() { "); - p.pln("return _type_ids;"); + p.pln("return (String[]) _type_ids.clone();"); p.pOln("}"); // Get all the methods and write each stub method... @@ -1860,11 +1860,11 @@ { if(POATie){ p.plnI("public String[] _all_interfaces(org.omg.PortableServer.POA poa, byte[] objectId){"); - p.pln("return _type_ids;"); + p.pln("return (String[]) _type_ids.clone();"); p.pOln("}"); } else { p.plnI("public String[] _ids() { "); - p.pln("return _type_ids;"); + p.pln("return (String[]) _type_ids.clone();"); p.pOln("}"); } }