mirror of
https://github.com/pgpainless/pgpainless.git
synced 2024-11-23 04:42:06 +01:00
Fix NPEs in KeyRingInfo.getExpirationDateForUse()
This commit is contained in:
parent
09ba0c954d
commit
a6e5ca898f
1 changed files with 8 additions and 4 deletions
|
@ -660,12 +660,16 @@ public class KeyRingInfo {
|
|||
}
|
||||
|
||||
if (nonExpiringSubkeys.isEmpty()) {
|
||||
if (latestSubkeyExpirationDate.before(primaryExpiration)) {
|
||||
return latestSubkeyExpirationDate;
|
||||
if (latestSubkeyExpirationDate != null) {
|
||||
if (primaryExpiration == null) {
|
||||
return latestSubkeyExpirationDate;
|
||||
}
|
||||
if (latestSubkeyExpirationDate.before(primaryExpiration)) {
|
||||
return latestSubkeyExpirationDate;
|
||||
}
|
||||
}
|
||||
return primaryExpiration;
|
||||
}
|
||||
return null;
|
||||
return primaryExpiration;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in a new issue