Catch and ignore NoSuchElementException when accessing CN attribute of a subject principal

git-svn-id: https://svn.apache.org/repos/asf/httpcomponents/httpclient/trunk@1614270 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Oleg Kalnichevski 2014-07-29 07:13:54 +00:00
parent 0852f1b4d8
commit 770285d505
1 changed files with 2 additions and 0 deletions

View File

@ -38,6 +38,7 @@ import java.util.Iterator;
import java.util.LinkedList;
import java.util.List;
import java.util.Locale;
import java.util.NoSuchElementException;
import javax.naming.InvalidNameException;
import javax.naming.NamingException;
@ -213,6 +214,7 @@ public abstract class AbstractCommonHostnameVerifier extends AbstractBaseHostnam
if (value != null) {
cns.add(value.toString());
}
} catch (NoSuchElementException ignore) {
} catch (NamingException ignore) {
}
}