Uploaded image for project: 'Runtime'
  1. Runtime
  2. RUNTIME-740

LDAPUsersManager log unexpected error

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • 2.4.2, 2.5
    • 2.3.1
    • Plugin core
    • None

      Method result.hasMoreElement() has not to be called two times, if the first call returns false.
      With some LDAP, this method could return false at first call and true at second call.

      Thne, the algorithm of methods like getUser(String login) must be corrected as bellow :

      results = doSearch()

      if (results.hasMoreElements())
      {
      [...]
      if (results.hasMoreElements())

      { getLogger().error([..]); }

      }

      instead:

      results = doSearch()

      if (results.hasMoreElements())

      { [...] }

      if (results.hasMoreElements())

      { getLogger().error([..]); }

            ngavalda Nicolas Gavalda (Inactive)
            ogehin Olivier Gehin
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: