pdu: drop ISCSI_PDU_NO_CALLBACK

we use the flag ISCSI_PDU_NO_CALLBACK and pdu->callback simultaneously, but
check only for one of them in various places. So drop ISCSI_PDU_NO_CALLBACK
and check for pdu->callback != NULL instead.

All PDUs that carried this flag have pdu->callback set to NULL.

Signed-off-by: Peter Lieven <pl@kamp.de>
This commit is contained in:
Peter Lieven
2016-05-02 10:40:15 +02:00
parent 03fe4d73f7
commit cde2043891
5 changed files with 22 additions and 28 deletions
+1 -1
View File
@@ -101,7 +101,7 @@ iscsi_send_target_nop_out(struct iscsi_context *iscsi, uint32_t ttt, uint32_t lu
ISCSI_PDU_NOP_OUT,
ISCSI_PDU_NO_PDU,
0xffffffff,
ISCSI_PDU_DROP_ON_RECONNECT|ISCSI_PDU_DELETE_WHEN_SENT|ISCSI_PDU_NO_CALLBACK);
ISCSI_PDU_DROP_ON_RECONNECT|ISCSI_PDU_DELETE_WHEN_SENT);
if (pdu == NULL) {
iscsi_set_error(iscsi, "Failed to allocate nop-out pdu");
return -1;