Uploaded image for project: 'Lustre'
  1. Lustre
  2. LU-8224

Possibly access of bad pointer in mdt_obd_connect()

Details

    • Bug
    • Resolution: Fixed
    • Minor
    • None
    • None
    • None
    • 3
    • 9223372036854775807

    Description

      In mdt_obd_connect we have:

              if ((data->ocd_connect_flags & OBD_CONNECT_MDS_MDS) &&
                  !(data->ocd_connect_flags & OBD_CONNECT_LIGHTWEIGHT)) {
                      atomic_inc(&mdt->mdt_mds_mds_conns);
                      mdt_enable_slc(mdt);
              }
              if (!test_bit(MDT_FL_SYNCED, &mdt->mdt_state) && data != NULL &&
      

      So it's either we should drop the data != NULL check or also check it above or do something els.e

      Otherwise it just looks kind of bad and also confuses static code analyzers.

      Attachments

        Issue Links

          Activity

            [LU-8224] Possibly access of bad pointer in mdt_obd_connect()

            Fixed in patch http://review.whamcloud.com/20391 "LU-8182 mdt: check connection data properly"

            adilger Andreas Dilger added a comment - Fixed in patch http://review.whamcloud.com/20391 " LU-8182 mdt: check connection data properly "

            This was filed in the wrong project.

            adilger Andreas Dilger added a comment - This was filed in the wrong project.

            People

              wc-triage WC Triage
              green Oleg Drokin
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: