diff options
author | Alexey Ushakov <alexey.v.ushakov@gmail.com> | 2019-04-24 13:55:02 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-04-24 13:55:02 +0300 |
commit | 9e0241d90097aa681d96ff6573e147caf9a2db39 (patch) | |
tree | c244131ab5ba8f552c9ae66ec119f3763af4a6fe | |
parent | 4c4c7c02466d22c284957f49dcd1ef1cd07ce3cc (diff) | |
parent | 4b424c1104399bce9563fb8485acd8b190fb6faa (diff) | |
download | jdk8u_jaxp-jb8u212-b1598.tar.gz |
Merge pull request #2 from bell-sw/update_8u212jb8u212-b1602jb8u212-b1601jb8u212-b1600jb8u212-b1598jb8u212-b1597jb8u212-b1596.1jb8u212-b1596jb8u212-b1595jb8u212-b1591.1jb8u212-b1591jb8u212-b1587.2jb8u212-b1587jb8u212-b1586.9jb8u212-b1586.4jb8u212-b1586.16jb8u212-b1586.14jb8u212-b1586.12jb8u212-b1586.11jb8u212-b1586.10jb8u212-b1580jb8u212-b1569jb8u212-b1566.8jb8u212-b1566.7jb8u212-b1566.6jb8u212-b1566.5jb8u202-b1562jb8u202-b1556jb8u202-b1555
jdk-8u212 update
-rw-r--r-- | .hgtags | 17 | ||||
-rw-r--r-- | THIRD_PARTY_README | 27 | ||||
-rw-r--r-- | src/com/sun/xml/internal/stream/util/ThreadLocalBufferAllocator.java | 24 |
3 files changed, 31 insertions, 37 deletions
@@ -985,3 +985,20 @@ ace766139b0a8b3df9ba5997410b6757e9e966ce jdk8u201-b77 83dce201f51fcaf5e20518d2d8f843a267587680 jdk8u201-b25 a55558a5e910f2336b24784592f77f4fa848fdb2 jdk8u201-b26 0bd4dbc4d66ff1a8ed6cc2095c19f9339283d274 jdk8u201-ga +5c4f2cff396cb24e33e18dbc0e9b7f5b757c299c jdk8u202-b01 +c6d5e32c8ce2e363f74b892f0b2f8a1f834d3396 jdk8u202-b02 +d492c0449092f847c0cd5ac54f6cae87285c50aa jdk8u202-b03 +521708c35dd0b9f59db8312da512193a66bbb462 jdk8u202-b04 +d61ae55f24a97aa0b11ca3ec16082488cc487c13 jdk8u202-b05 +9f0f2cf7a03d12ce7c7797e073022ec8b0306e2e jdk8u202-b06 +f9ce9e9e966acd4b057e7fdd024f032c6501cec8 jdk8u202-b07 +6c6166477778069fbb8bddda0b2bd490c5165fe4 jdk8u202-b08 +2e575d455cacab1117667d73f81bc2774c0408af jdk8u202-b25 +a14b334da6a14ff6c800888b31a621671ddedcd4 jdk8u202-b26 +6c6166477778069fbb8bddda0b2bd490c5165fe4 jdk8u202-ga +58a54ab25e5201d29fea1ed1e165c95ce479f5cf jdk8u212-b00 +22d26c0a8eb7ddfdbebf835c59b07e8b8da47359 jdk8u212-b01 +8b263aef666d72459ac637e3ff19554c9fb4e7ca jdk8u212-b02 +7dca173f654edf0720e62b72ef750c673bc6ebfe jdk8u212-b03 +90f8352e7f0642918735d66c38b3c6c44473691a jdk8u212-b04 +7dca173f654edf0720e62b72ef750c673bc6ebfe jdk8u212-ga diff --git a/THIRD_PARTY_README b/THIRD_PARTY_README index f9268ad..2247356 100644 --- a/THIRD_PARTY_README +++ b/THIRD_PARTY_README @@ -1096,33 +1096,6 @@ IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. --- end of LICENSE --- -%% This notice is provided with respect to FontConfig 2.5, which may be -included with JRE 8, JDK 8, and OpenJDK 8 source distributions on -Linux and Solaris. - ---- begin of LICENSE --- - -Copyright ?? 2001,2003 Keith Packard - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that the -above copyright notice appear in all copies and that both that copyright -notice and this permission notice appear in supporting documentation, and that -the name of Keith Packard not be used in advertising or publicity pertaining -to distribution of the software without specific, written prior permission. -Keith Packard makes no representations about the suitability of this software -for any purpose. It is provided "as is" without express or implied warranty. - -KEITH PACKARD DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING -ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL KEITH -PACKARD BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY -DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN -ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN -CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - - ---- end of LICENSE --- - ------------------------------------------------------------------------------- %% This notice is provided with respect to freebXML Registry 3.0 & 3.1, diff --git a/src/com/sun/xml/internal/stream/util/ThreadLocalBufferAllocator.java b/src/com/sun/xml/internal/stream/util/ThreadLocalBufferAllocator.java index 25bdf6b..5f4243d 100644 --- a/src/com/sun/xml/internal/stream/util/ThreadLocalBufferAllocator.java +++ b/src/com/sun/xml/internal/stream/util/ThreadLocalBufferAllocator.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2005, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2005, 2018, 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 @@ -39,15 +39,19 @@ import java.lang.ref.*; * @author Santiago.PericasGeertsen@sun.com */ public class ThreadLocalBufferAllocator { - private static ThreadLocal tlba = new ThreadLocal(); + private static final ThreadLocal<SoftReference<BufferAllocator>> TL = new ThreadLocal<>(); - public static BufferAllocator getBufferAllocator() { - SoftReference bAllocatorRef = (SoftReference) tlba.get(); - if (bAllocatorRef == null || bAllocatorRef.get() == null) { - bAllocatorRef = new SoftReference(new BufferAllocator()); - tlba.set(bAllocatorRef); + public static BufferAllocator getBufferAllocator() { + BufferAllocator ba = null; + SoftReference<BufferAllocator> sr = TL.get(); + if (sr != null) { + ba = sr.get(); } - - return (BufferAllocator) bAllocatorRef.get(); - } + if (ba == null) { + ba = new BufferAllocator(); + sr = new SoftReference<>(ba); + TL.set(sr); + } + return ba; + } } |