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

Fix incorrect null value check

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.8.3, 3.0.0
    • Fix Version/s: 3.1.0, 2.10.0
    • Component/s: hdfs
    • Labels:
      None
    • Hadoop Flags:
      Reviewed

      Description

       

      public void setZoneName(final String name) {
        Preconditions.checkNotNull(name == null)-------error parameter for checkNotNull
        zoneName = name;
      }
      

      Like above, in 3.x, the checkNotNull function gets wrong parameter in two cases: ZoneReencryptionStatus#setZoneName and AdminHelper#HelpCommand#HelpCommand

      In 2.x, the error occurs once in AdminHelper#HelpCommand#HelpCommand

       

        Attachments

        1. HDFS-13261.001.patch
          1 kB
          Jianfei Jiang
        2. HDFS-13261.002.patch
          2 kB
          Jianfei Jiang
        3. HDFS-13261.002-branch-2.patch
          0.7 kB
          Jianfei Jiang

          Issue Links

            Activity

              People

              • Assignee:
                jiangjianfei Jianfei Jiang
                Reporter:
                jiangjianfei Jianfei Jiang
              • Votes:
                0 Vote for this issue
                Watchers:
                5 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: