You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by ma...@apache.org on 2015/10/06 19:01:28 UTC
svn commit: r1707090 -
/tomcat/trunk/java/org/apache/tomcat/util/file/ConfigFileLoader.java
Author: markt
Date: Tue Oct 6 17:01:28 2015
New Revision: 1707090
URL: http://svn.apache.org/viewvc?rev=1707090&view=rev
Log:
Tab police
Modified:
tomcat/trunk/java/org/apache/tomcat/util/file/ConfigFileLoader.java
Modified: tomcat/trunk/java/org/apache/tomcat/util/file/ConfigFileLoader.java
URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/util/file/ConfigFileLoader.java?rev=1707090&r1=1707089&r2=1707090&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/tomcat/util/file/ConfigFileLoader.java (original)
+++ tomcat/trunk/java/org/apache/tomcat/util/file/ConfigFileLoader.java Tue Oct 6 17:01:28 2015
@@ -56,21 +56,21 @@ public class ConfigFileLoader {
* provided location
*/
public static InputStream getInputStream(String location) throws IOException {
- // Absolute URIs will be left alone
+ // Absolute URIs will be left alone
// Relative files will be resolved relative to catalina base
// Absolute files will be converted to URIs
- URI uri;
- if (location != null &&
- (location.length() > 2 && ":\\".equals(location.substring(1, 3)) ||
- location.startsWith("\\\\"))) {
- // This is an absolute file path in Windows or a UNC path
- File f = new File(location);
- uri =f.getAbsoluteFile().toURI();
- } else {
- // URL, relative path or an absolute path on a non-Windows platforms
- uri = CATALINA_BASE_URI.resolve(location);
- }
- URL url = uri.toURL();
+ URI uri;
+ if (location != null &&
+ (location.length() > 2 && ":\\".equals(location.substring(1, 3)) ||
+ location.startsWith("\\\\"))) {
+ // This is an absolute file path in Windows or a UNC path
+ File f = new File(location);
+ uri =f.getAbsoluteFile().toURI();
+ } else {
+ // URL, relative path or an absolute path on a non-Windows platforms
+ uri = CATALINA_BASE_URI.resolve(location);
+ }
+ URL url = uri.toURL();
return url.openConnection().getInputStream();
}
}
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org