[java-identity-provider] branch main updated: IDP-1833 - Wildcard classpath breaks inside flow imports on Windows
Scott Cantor
cantor.2 at osu.edu
Mon Jul 19 14:04:47 UTC 2021
This is an automated email from the git hooks/post-receive script.
scantor pushed a commit to branch main
in repository java-identity-provider.
View the commit online:
http://git.shibboleth.net/view/?p=java-identity-provider.git;a=commit;h=2bad5bbdf36fc46d1603db4b0e93a6991c510493
The following commit(s) were added to refs/heads/main by this push:
new 2bad5bbdf IDP-1833 - Wildcard classpath breaks inside flow imports on Windows
2bad5bbdf is described below
commit 2bad5bbdf36fc46d1603db4b0e93a6991c510493
Author: Scott Cantor <cantor.2 at osu.edu>
AuthorDate: Mon Jul 19 09:50:18 2021 -0400
IDP-1833 - Wildcard classpath breaks inside flow imports on Windows
https://issues.shibboleth.net/jira/browse/IDP-1833
Guard code path with exception catch.
---
.../spring/factory/FlowRelativeResourceLoader.java | 20 ++++++++++++++------
1 file changed, 14 insertions(+), 6 deletions(-)
diff --git a/idp-profile-spring/src/main/java/net/shibboleth/idp/profile/spring/factory/FlowRelativeResourceLoader.java b/idp-profile-spring/src/main/java/net/shibboleth/idp/profile/spring/factory/FlowRelativeResourceLoader.java
index 704c3744a..41a572fab 100644
--- a/idp-profile-spring/src/main/java/net/shibboleth/idp/profile/spring/factory/FlowRelativeResourceLoader.java
+++ b/idp-profile-spring/src/main/java/net/shibboleth/idp/profile/spring/factory/FlowRelativeResourceLoader.java
@@ -58,9 +58,13 @@ class FlowRelativeResourceLoader extends DefaultResourceLoader {
@Override
public Resource getResource(final String location) {
- final Resource r = super.getResource(location);
- if (r.exists()) {
- return r;
+ try {
+ final Resource r = super.getResource(location);
+ if (r.exists()) {
+ return r;
+ }
+ } catch (final Exception e) {
+ // May happen if resource wrapper throws during exists() call.
}
if (location.startsWith(CLASSPATH_URL_PREFIX)) {
@@ -92,9 +96,13 @@ class FlowRelativeResourceLoader extends DefaultResourceLoader {
*/
@Override
protected Resource getResourceByPath(final String path) {
- final Resource r = new FileSystemResource(path);
- if (r.exists()) {
- return r;
+ try {
+ final Resource r = new FileSystemResource(path);
+ if (r.exists()) {
+ return r;
+ }
+ } catch (final Exception e) {
+ // May happen if resource wrapper throws during exists() call.
}
return super.getResourceByPath(path);
}
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
More information about the commits
mailing list