[LU-7950] Suspicious dereference of pointer before NULL check in lwp_device_fini() Created: 29/Mar/16  Updated: 13/Sep/16  Resolved: 13/Sep/16

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

Type: Bug Priority: Minor
Reporter: Dmitry Eremin (Inactive) Assignee: Dmitry Eremin (Inactive)
Resolution: Fixed Votes: 0
Labels: kw, patch

Issue Links:
Related
is related to LU-8378 unused but set variables Resolved
Severity: 3
Rank (Obsolete): 9223372036854775807

 Description   

Suspicious dereference of pointer 'm->lpd_obd' before NULL check at line 377

  • An event which alters the program's state, leading to the defect
    lwp_dev.c:375: 'm->lpd_obd' is dereferenced.
  • An event which alters the program's state, leading to the defect
    lwp_dev.c:377: 'm->lpd_obd' is checked for NULL.
375			imp = m->lpd_obd->u.cli.cl_import;
376		 
377			LASSERT(m->lpd_obd);


 Comments   
Comment by Dmitry Eremin (Inactive) [ 29/Mar/16 ]

the same in osp_device_fini():
Suspicious dereference of pointer 'osp->opd_obd' before NULL check at line 1341

Comment by Gerrit Updater [ 28/Jun/16 ]

Arshad Hussain (arshad.super@gmail.com) uploaded a new patch: http://review.whamcloud.com/21024
Subject: LU-7950 osp: Move assignment below LASSERT()
Project: fs/lustre-release
Branch: master
Current Patch Set: 1
Commit: db6494631db78f0984f149361e6caf963c059619

Comment by Peter Jones [ 28/Jun/16 ]

Dmitry

Could you please review this patch when you are back in the office?

Thanks

Peter

Comment by Gerrit Updater [ 29/Jun/16 ]

Arshad Hussain (arshad.super@gmail.com) uploaded a new patch: http://review.whamcloud.com/21066
Subject: LU-7950 osp: Remove assigned but not used variable
Project: fs/lustre-release
Branch: master
Current Patch Set: 1
Commit: 58c45164de896ac6eae8c09fb38f8f40e399f125

Comment by Gerrit Updater [ 13/Sep/16 ]

Oleg Drokin (oleg.drokin@intel.com) merged in patch http://review.whamcloud.com/21024/
Subject: LU-7950 osp: Remove assigned but not used variable
Project: fs/lustre-release
Branch: master
Current Patch Set:
Commit: 107c1d022ffd976b4a335f794de731cf9d57a514

Comment by Peter Jones [ 13/Sep/16 ]

Landed for 2.9

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