diff options
author | Rawi01 <Rawi01@users.noreply.github.com> | 2020-08-31 09:57:29 +0200 |
---|---|---|
committer | Rawi01 <Rawi01@users.noreply.github.com> | 2020-08-31 09:57:29 +0200 |
commit | 82ac8aad1d0e3e152db4ce328184c40c73700cee (patch) | |
tree | 3d5abb9072d43b87f19e5faf88a3d09b6c6da8e4 /src/utils/lombok/core/SpiLoadUtil.java | |
parent | 3d90a51163354930eeea0e26c2b0a567af8e96be (diff) | |
parent | 9148294f78a8e646ee131ca182a9b692bc028fdb (diff) | |
download | lombok-82ac8aad1d0e3e152db4ce328184c40c73700cee.tar.gz lombok-82ac8aad1d0e3e152db4ce328184c40c73700cee.tar.bz2 lombok-82ac8aad1d0e3e152db4ce328184c40c73700cee.zip |
Merge branch 'master' into extensionmethod
Conflicts:
build.xml
Diffstat (limited to 'src/utils/lombok/core/SpiLoadUtil.java')
-rw-r--r-- | src/utils/lombok/core/SpiLoadUtil.java | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/utils/lombok/core/SpiLoadUtil.java b/src/utils/lombok/core/SpiLoadUtil.java index e685acd6..0feb7f12 100644 --- a/src/utils/lombok/core/SpiLoadUtil.java +++ b/src/utils/lombok/core/SpiLoadUtil.java @@ -129,9 +129,10 @@ public class SpiLoadUtil { private static void readServicesFromUrl(Collection<String> list, URL url) throws IOException { InputStream in = url.openStream(); + BufferedReader r = null; try { if (in == null) return; - BufferedReader r = new BufferedReader(new InputStreamReader(in, "UTF-8")); + r = new BufferedReader(new InputStreamReader(in, "UTF-8")); while (true) { String line = r.readLine(); if (line == null) break; @@ -143,6 +144,7 @@ public class SpiLoadUtil { } } finally { try { + if (r != null) r.close(); if (in != null) in.close(); } catch (Throwable ignore) {} } |