This is an automated email from the ASF dual-hosted git repository.
mattsicker pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/logging-log4j2.git
The following commit(s) were added to refs/heads/master by this push:
new eea4b5d7b0 Remove unused method
eea4b5d7b0 is described below
commit eea4b5d7b044f76c9398a546355424dc8b462f02
Author: Matt Sicker <[email protected]>
AuthorDate: Sat Nov 19 12:37:37 2022 -0600
Remove unused method
Signed-off-by: Matt Sicker <[email protected]>
---
.../apache/logging/log4j/util/PropertiesUtil.java | 27 ----------------------
1 file changed, 27 deletions(-)
diff --git
a/log4j-api/src/main/java/org/apache/logging/log4j/util/PropertiesUtil.java
b/log4j-api/src/main/java/org/apache/logging/log4j/util/PropertiesUtil.java
index a12a22538e..643e52b734 100644
--- a/log4j-api/src/main/java/org/apache/logging/log4j/util/PropertiesUtil.java
+++ b/log4j-api/src/main/java/org/apache/logging/log4j/util/PropertiesUtil.java
@@ -16,8 +16,6 @@
*/
package org.apache.logging.log4j.util;
-import java.io.IOException;
-import java.io.InputStream;
import java.lang.invoke.MethodHandles;
import java.util.ArrayList;
import java.util.HashSet;
@@ -85,31 +83,6 @@ public class PropertiesUtil implements PropertyEnvironment {
this.environment = new Environment(source);
}
- /**
- * Loads and closes the given property input stream. If an error occurs,
log to the status logger.
- *
- * @param in a property input stream.
- * @param source a source object describing the source, like a resource
string or a URL.
- * @return a new Properties object
- */
- static Properties loadClose(final InputStream in, final Object source) {
- final Properties props = new Properties();
- if (null != in) {
- try {
- props.load(in);
- } catch (final IOException e) {
- LowLevelLogUtil.logException("Unable to read " + source, e);
- } finally {
- try {
- in.close();
- } catch (final IOException e) {
- LowLevelLogUtil.logException("Unable to close " + source,
e);
- }
- }
- }
- return props;
- }
-
/**
* Returns the PropertiesUtil used by Log4j.
*