mirror of
https://github.com/M66B/FairEmail.git
synced 2024-12-22 07:42:52 +00:00
Prevent NPE
This commit is contained in:
parent
371814d1da
commit
0d5aafb1f9
1 changed files with 4 additions and 1 deletions
|
@ -224,7 +224,9 @@ public class EntityCertificate {
|
|||
List<RDN> rdns = new ArrayList<>();
|
||||
rdns.addAll(Arrays.asList(name.getRDNs(BCStyle.CN)));
|
||||
rdns.addAll(Arrays.asList(name.getRDNs(BCStyle.EmailAddress)));
|
||||
for (RDN rdn : rdns)
|
||||
for (RDN rdn : rdns) {
|
||||
if (rdn == null)
|
||||
continue;
|
||||
for (AttributeTypeAndValue tv : rdn.getTypesAndValues()) {
|
||||
ASN1Encodable enc = tv.getValue();
|
||||
if (enc == null)
|
||||
|
@ -237,6 +239,7 @@ public class EntityCertificate {
|
|||
result.add(MessageHelper.fromPunyCode(email));
|
||||
}
|
||||
}
|
||||
}
|
||||
} catch (Throwable ex) {
|
||||
Log.e(ex);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue