Uploaded image for project: 'Hadoop HDFS'
  1. Hadoop HDFS
  2. HDFS-7567

Potential null dereference in FSEditLogLoader#applyEditLogOp()

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Later
    • None
    • None
    • None
    • None

    Description

            INodeFile oldFile = INodeFile.valueOf(iip.getLastINode(), path, true);
            if (oldFile != null && addCloseOp.overwrite) {
      ...
            INodeFile newFile = oldFile;
      ...
            // Update the salient file attributes.
            newFile.setAccessTime(addCloseOp.atime, Snapshot.CURRENT_STATE_ID);
            newFile.setModificationTime(addCloseOp.mtime, Snapshot.CURRENT_STATE_ID);
      

      The last two lines are not protected by null check.

      Attachments

        1. hdfs-7567.patch
          0.9 kB
          Ted Yu

        Issue Links

          Activity

            People

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

              Dates

                Created:
                Updated:
                Resolved: