TESTS: Add comment to describe why we keep a pointer around for iscsi_queue_pdu

Signed-off-by: Ronnie Sahlberg <ronniesahlberg@gmail.com>
This commit is contained in:
Ronnie Sahlberg
2015-06-01 21:16:39 -07:00
parent 86a42c8b3a
commit 95d763d9f9

View File

@@ -1077,7 +1077,12 @@ main(int argc, char *argv[])
mp_num_sds++;
}
/* XXX why is this done? */
/* So that we can override iscsi_queue_pdu in tests
* and replace or mutate the blob that we are about to write to the
* wire.
* This allows such tests to do their mutates and then call out
* to the real queueing function once they have modified the data.
*/
real_iscsi_queue_pdu = dlsym(RTLD_NEXT, "iscsi_queue_pdu");
if ((mp_num_sds == 0) || (mp_sds[0]->iscsi_url == NULL