Libiscsi users need a way to check if a task is queued to send (not sent yet) before invoking functions such as iscsi_task_mgmt_abort_task_async. Otherwise, because task management requests are automatically treated as "immediate", a request to abort a task is sent before the task itself.
Libiscsi users need a way to check if a task is queued to send (not sent yet) before invoking functions such as iscsi_task_mgmt_abort_task_async. Otherwise, because task management requests are automatically treated as "immediate", a request to abort a task is sent before the task itself.
if (iscsi_scsi_is_task_inoutqueue(iscsi, task_)) { iscsi_scsi_canceltask(iscsi, task_); } else { iscsi_task_mgmt_abort_taskasync(iscsi, task, AbortCb, context); }