mirror of
https://github.com/SCST-project/scst.git
synced 2026-05-21 04:31:26 +00:00
qla2x00t: Keep smatch happy (merge r4486 from trunk)
Smatch reports two warnings on the qla2x00t code: * sess->local being tested while sess can be NULL. * The code after the out_unreg_target2x label is only necessary in the procfs build. git-svn-id: http://svn.code.sf.net/p/scst/svn/branches/2.2.x@4629 d57e44dd-8a1f-0410-8b47-8ef2f437770f
This commit is contained in:
@@ -1274,7 +1274,7 @@ static void q2t_fc_port_added(scsi_qla_host_t *ha, fc_port_t *fcport)
|
||||
sess->conf_compl_supported = fcport->conf_compl_supported;
|
||||
}
|
||||
|
||||
if (sess->local) {
|
||||
if (sess && sess->local) {
|
||||
TRACE(TRACE_MGMT, "qla2x00t(%ld): local session for "
|
||||
"port %02x:%02x:%02x:%02x:%02x:%02x:%02x:%02x "
|
||||
"(loop ID %d) became global", ha->instance,
|
||||
@@ -6634,9 +6634,9 @@ out:
|
||||
|
||||
#ifdef CONFIG_SCST_PROC
|
||||
out_unreg_target2x:
|
||||
#endif
|
||||
scst_unregister_target_template(&tgt2x_template);
|
||||
qla2xxx_tgt_unregister_driver();
|
||||
#endif
|
||||
|
||||
out_mempool_free:
|
||||
mempool_destroy(q2t_mgmt_cmd_mempool);
|
||||
|
||||
Reference in New Issue
Block a user