[java-shib-attribute] branch main updated: Fix a null bug.
Scott Cantor
cantor.2 at osu.edu
Mon Apr 24 18:05:27 UTC 2023
This is an automated email from the git hooks/post-receive script.
scantor pushed a commit to branch main
in repository java-shib-attribute.
View the commit online:
http://git.shibboleth.net/view/?p=java-shib-attribute.git;a=commit;h=2f115a0d17a4757971c4b1c4478041622139f8e7
The following commit(s) were added to refs/heads/main by this push:
new 2f115a0d1 Fix a null bug.
2f115a0d1 is described below
commit 2f115a0d17a4757971c4b1c4478041622139f8e7
Author: Scott Cantor <cantor.2 at osu.edu>
AuthorDate: Mon Apr 24 14:05:25 2023 -0400
Fix a null bug.
---
.../idp/attribute/resolver/spring/dc/impl/CacheConfigParser.java | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/shib-attribute-resolver-spring/src/main/java/net/shibboleth/idp/attribute/resolver/spring/dc/impl/CacheConfigParser.java b/shib-attribute-resolver-spring/src/main/java/net/shibboleth/idp/attribute/resolver/spring/dc/impl/CacheConfigParser.java
index d462c88a1..831e255ea 100644
--- a/shib-attribute-resolver-spring/src/main/java/net/shibboleth/idp/attribute/resolver/spring/dc/impl/CacheConfigParser.java
+++ b/shib-attribute-resolver-spring/src/main/java/net/shibboleth/idp/attribute/resolver/spring/dc/impl/CacheConfigParser.java
@@ -97,6 +97,8 @@ public class CacheConfigParser {
}
final Element cacheElement = cacheElements.get(0);
+ assert cacheElement != null;
+
final String expireAfterWrite =
AttributeSupport.getAttributeValue(cacheElement, new QName("expireAfterWrite"));
final String expireAfterAccess =
@@ -137,7 +139,10 @@ public class CacheConfigParser {
*/
@Nonnull private static Duration getTimeToLive(@Nullable final String timeToLive) {
if (timeToLive != null) {
- return new StringToDurationConverter().convert(timeToLive);
+ final Duration d = new StringToDurationConverter().convert(timeToLive);
+ if (d != null) {
+ return d;
+ }
}
return DEFAULT_TTL_MS;
}
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
More information about the commits
mailing list