diff options
author | Jesse Wilson <jessewilson@google.com> | 2010-11-04 14:02:20 -0700 |
---|---|---|
committer | Jesse Wilson <jessewilson@google.com> | 2010-11-04 14:02:20 -0700 |
commit | ccd79e2bb784cdbd89e90a0e4301a707091d446d (patch) | |
tree | 3eb0e619b9394bf16c6ad7781f67945004468d7f /dom | |
parent | 700ec1f739329bd2deede32cc72affa473d737cc (diff) | |
download | libcore-ccd79e2bb784cdbd89e90a0e4301a707091d446d.zip libcore-ccd79e2bb784cdbd89e90a0e4301a707091d446d.tar.gz libcore-ccd79e2bb784cdbd89e90a0e4301a707091d446d.tar.bz2 |
Style cleanup of some XML code.
Motivation: in preparation to refactor the Kxml code I'd like
to bring this code to a style consistent with the rest of
Android. This code style currently disagrees with my toolchain.
Change-Id: Ibd24570c131e792532e46f7f44c64abac3a6979a
http://b/3090550
Diffstat (limited to 'dom')
-rw-r--r-- | dom/src/test/java/org/w3c/domts/JAXPDOMTestDocumentBuilderFactory.java | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/dom/src/test/java/org/w3c/domts/JAXPDOMTestDocumentBuilderFactory.java b/dom/src/test/java/org/w3c/domts/JAXPDOMTestDocumentBuilderFactory.java index c2d105e..0ca8f1f 100644 --- a/dom/src/test/java/org/w3c/domts/JAXPDOMTestDocumentBuilderFactory.java +++ b/dom/src/test/java/org/w3c/domts/JAXPDOMTestDocumentBuilderFactory.java @@ -12,6 +12,7 @@ package org.w3c.domts; +import java.io.InputStream; import javax.xml.parsers.DocumentBuilder; import javax.xml.parsers.DocumentBuilderFactory; import javax.xml.parsers.ParserConfigurationException; @@ -120,7 +121,9 @@ public class JAXPDOMTestDocumentBuilderFactory try { LoadErrorHandler errorHandler = new LoadErrorHandler(); builder.setErrorHandler(errorHandler); - doc = builder.parse(url.openStream(), url.toString()); + InputStream stream = url.openStream(); + doc = builder.parse(stream, url.toString()); + stream.close(); parseException = errorHandler.getFirstException(); } catch (Exception ex) { |