[PATCH] 7164256 : EnumMap.clone doesn't clear the entrySet field, keeping a reference to the original Map (original) (raw)
Diego Belfer dbelfer at gmail.com
Sat May 26 19:30:59 UTC 2012
- Previous message: hg: jdk8/tl/jdk: 39 new changesets
- Next message: [PATCH] 7164256 : EnumMap.clone doesn't clear the entrySet field, keeping a reference to the original Map
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Hello,
I have reported a bug in the implementation of the clone method of the EnumMap class. The instance field entrySet is not being cleared, so the entrySet field of the new instance references to the original EnumMap.
I am providing a simple patch for review. It adds one line to the clone method that sets the entrySet field to null.
This is my first contribution to the OpenJDK, so let me know if I am missing some step of the process.
Thanks, Diego Belfer [muralx]
- Previous message: hg: jdk8/tl/jdk: 39 new changesets
- Next message: [PATCH] 7164256 : EnumMap.clone doesn't clear the entrySet field, keeping a reference to the original Map
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]