Uploaded image for project: 'ZooKeeper'
  1. ZooKeeper
  2. ZOOKEEPER-68

parseACLs in ZooKeeper.java fails to parse elements of ACL, should be lastIndexOf rather than IndexOf

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • None
    • 3.0.0
    • java client
    • None
    • Reviewed

    Description

      the parseACLs(String aclString) method attempts to prase ACLs from the form of scheme:id:perm into the three components, delineated by the colons. The current version calls indexOf for both the first and second colon, receiving the same value for both and failing as if there were only one colon in the string. I created a one-line patch to call lastIndexOf for the second colon.

      Attachments

        1. colonindices.diff
          0.6 kB
          Jakob Homan
        2. ZOOKEEPER-68_1.patch
          0.7 kB
          Mahadev Konar

        Activity

          People

            mahadev Mahadev Konar
            jghoman Jakob Homan
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: