mirror of
https://github.com/SCST-project/scst.git
synced 2026-08-22 07:06:22 +00:00
iscsi-scst: fix a couple of bad-function-cast warnings
This is a "marginal" warning, but there are only six of them in the SCST code and this fixes two of those. session.c:105:4: warning: cast from function call of type void * to non-matching type _Bool [-Wbad-function-cast] target.c:668:14: warning: cast from function call of type void * to non-matching type _Bool [-Wbad-function-cast] Signed-off-by: David Butterfield <dab21774@gmail.com> git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7200 d57e44dd-8a1f-0410-8b47-8ef2f437770f
This commit is contained in:
@@ -102,7 +102,7 @@ static int iscsi_session_alloc(struct iscsi_target *target,
|
||||
|
||||
if (!session->sess_params.rdma_extensions) {
|
||||
err = iscsi_threads_pool_get(
|
||||
(bool)scst_get_acg_tgt_priv(session->scst_sess->acg),
|
||||
scst_get_acg_tgt_priv(session->scst_sess->acg) != NULL,
|
||||
&session->scst_sess->acg->acg_cpu_mask,
|
||||
&session->sess_thr_pool);
|
||||
if (err != 0)
|
||||
|
||||
@@ -665,7 +665,7 @@ static ssize_t iscsi_acg_sess_dedicated_threads_show(struct kobject *kobj,
|
||||
TRACE_ENTRY();
|
||||
|
||||
acg = container_of(kobj, struct scst_acg, acg_kobj);
|
||||
dedicated = (bool)scst_get_acg_tgt_priv(acg);
|
||||
dedicated = scst_get_acg_tgt_priv(acg) != NULL;
|
||||
|
||||
pos = sprintf(buf, "%d\n%s", dedicated,
|
||||
dedicated ? SCST_SYSFS_KEY_MARK "\n" : "");
|
||||
|
||||
Reference in New Issue
Block a user