Commit 59bfb699 authored by Daniel Henninger's avatar Daniel Henninger Committed by dhenninger

Fixed poor handling of number parse issue.

git-svn-id: http://svn.igniterealtime.org/svn/repos/openfire/trunk@10773 b35dd754-fafc-0310-a699-88a17e54d16e
parent 3c814860
......@@ -1535,7 +1535,12 @@ public class LdapManager {
List<String> results = new ArrayList<String>();
int pageSize = -1;
String pageSizeStr = properties.get("ldap.pagedResultsSize");
try {
if (pageSizeStr != null) pageSize = Integer.parseInt(pageSizeStr, -1);
}
catch (NumberFormatException e) {
// poorly formatted number, ignoring
}
Boolean clientSideSort = false;
String clientSideSortStr = properties.get("ldap.clientSideSorting");
if (clientSideSortStr != null) clientSideSort = Boolean.valueOf(clientSideSortStr);
......@@ -1742,7 +1747,12 @@ public class LdapManager {
public Integer retrieveListCount(String attribute, String searchFilter) {
int pageSize = -1;
String pageSizeStr = properties.get("ldap.pagedResultsSize");
try {
if (pageSizeStr != null) pageSize = Integer.parseInt(pageSizeStr, -1);
}
catch (NumberFormatException e) {
// poorly formatted number, ignoring
}
LdapContext ctx = null;
LdapContext ctx2 = null;
Integer count = 0;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment