Index: jndi/src/main/java/javax/naming/CompoundName.java =================================================================== --- jndi/src/main/java/javax/naming/CompoundName.java (revision 433551) +++ jndi/src/main/java/javax/naming/CompoundName.java (working copy) @@ -370,7 +370,7 @@ private void init(Properties props) { trimBlanks = false; ignoreCase = false; - this.mySyntax = (Properties) props.clone(); + this.mySyntax = props; String property; //read property settings @@ -708,15 +708,7 @@ } public Object clone() { - CompoundName newName = null; - try { - newName = (CompoundName) super.clone(); - } catch (CloneNotSupportedException e) { - throw new Error("Failed to clone object of CompoundName class"); //$NON-NLS-1$ - } - newName.mySyntax = (Properties) mySyntax.clone(); - newName.elem = (Vector) elem.clone(); - return newName; + return new CompoundName(getAll(), mySyntax); } public int size() {