[LU-6517] lmv_disconnect_mdc dereferences a potential NULL pointer Created: 27/Apr/15  Updated: 25/May/15  Resolved: 25/May/15

Status: Resolved
Project: Lustre
Component/s: None
Affects Version/s: None
Fix Version/s: Lustre 2.8.0

Type: Bug Priority: Minor
Reporter: Oleg Drokin Assignee: WC Triage
Resolution: Fixed Votes: 0
Labels: None

Severity: 3
Rank (Obsolete): 9223372036854775807

 Description   

smatch found this piece in lmv_disconnect_mdc:

        if (mdc_obd) {
                mdc_obd->obd_force = obd->obd_force;
                mdc_obd->obd_fail = obd->obd_fail;
                mdc_obd->obd_no_recov = obd->obd_no_recov;
        }

        if (lmv->targets_proc_entry != NULL)
                lprocfs_remove_proc_entry(mdc_obd->obd_name,
                                          lmv->targets_proc_entry);


 Comments   
Comment by Gerrit Updater [ 27/Apr/15 ]

Oleg Drokin (oleg.drokin@intel.com) uploaded a new patch: http://review.whamcloud.com/14605
Subject: LU-6517 lmv: fix potential null pointer dereference
Project: fs/lustre-release
Branch: master
Current Patch Set: 1
Commit: d09a83b72c96d08787b96308b6f463aba9d82441

Comment by Oleg Drokin [ 27/Apr/15 ]

Or should we do it unconditionally and instead of getting the name from mdc_obd scrub the name from proc entry instead somehow?

Comment by Gerrit Updater [ 25/May/15 ]

Oleg Drokin (oleg.drokin@intel.com) merged in patch http://review.whamcloud.com/14605/
Subject: LU-6517 lmv: fix potential null pointer dereference
Project: fs/lustre-release
Branch: master
Current Patch Set:
Commit: 47c49d3cbb21c94c03831bb4d524d53772a1c2f9

Comment by Peter Jones [ 25/May/15 ]

Landed for 2.8

Generated at Sat Feb 10 02:00:54 UTC 2024 using Jira 9.4.14#940014-sha1:734e6822bbf0d45eff9af51f82432957f73aa32c.