Uploaded image for project: 'Apache Curator'
  1. Apache Curator
  2. CURATOR-395

Potential null dereference in PersistentNode

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • None
    • 4.0.0, 2.13.0
    • None
    • None

    Description

                  if ( localCreateMethod == null )
                  {
                      CreateModable<ACLBackgroundPathAndBytesable<String>> tempCreateMethod = useProtection ? client.create().creatingParentContainersIfNeeded().withProtection() : client.create().creatingParentContainersIfNeeded();
                      if ( createMethod.compareAndSet(null, tempCreateMethod) )
                      {
                          localCreateMethod = tempCreateMethod;
                      }
                  }
                  localCreateMethod.withMode(getCreateMode(existingPath != null)).inBackground(backgroundCallback).forPath(createPath, data.get());
      

      Before calling withMode(), localCreateMethod should be checked against null.

      Attachments

        Issue Links

          Activity

            People

              randgalt Jordan Zimmerman
              yuzhihong@gmail.com Ted Yu
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: