Warnings Cleanup in java.util. (more from hack day) (original) (raw)

Martijn Verburg martijnverburg at gmail.com
Fri Dec 2 14:28:26 PST 2011


Hi Rémi,

Doesn't that then use the deprecated String constructor?

Disclaimer - I was involved in that patch :)

Cheers, Martijn

On Friday, 2 December 2011, Rémi Forax <forax at univ-mlv.fr> wrote:

On 12/02/2011 08:24 PM, Michael Barker wrote:

Hi, We had some late submissions from our hack day participants. 2 more patches. One (j.u.z.ZipEntry) is possibly a little more involved for a warnings fix. It removes a usage of deprecated Date APIs in favour of Calendar. However, the fix results in code that is very similar to Apache Harmony implementation. The other is a couple of fixes for generics (j.u.j.Manifest). Thanks to: - Prasannaa Regards, Michael Barker mikeb2701 Hi Mickael, one change to Manifest.java introduces a bug ! - byte[] vb = value.getBytes("UTF8"); - value = new String(vb, 0, 0, vb.length); + byte[] vb = value.getBytes(StandardCharsets.UTF8); + value = new String(vb, 0, 0, StandardCharsets.UTF8); the last line should be: value = new String(vb, 0, 0, vb.length); cheers, Rémi



More information about the jdk8-dev mailing list