aboutsummaryrefslogtreecommitdiff
path: root/sys/cam/ctl/ctl_tpc.c
diff options
context:
space:
mode:
authorAlexander Motin <mav@FreeBSD.org>2014-08-02 23:20:43 +0000
committerAlexander Motin <mav@FreeBSD.org>2014-08-02 23:20:43 +0000
commitc5c6059574e490e06dc1fa29a0bf9c7167f6e487 (patch)
tree1077438260964aa1e3d428676bb3f987210c7b15 /sys/cam/ctl/ctl_tpc.c
parentdd973b0e151fc8b1c1670aa2211780a46f419935 (diff)
downloadsrc-c5c6059574e490e06dc1fa29a0bf9c7167f6e487.tar.gz
src-c5c6059574e490e06dc1fa29a0bf9c7167f6e487.zip
Rework r269444 to work also for lists without IDs.
MFC after: 3 days
Notes
Notes: svn path=/head/; revision=269450
Diffstat (limited to 'sys/cam/ctl/ctl_tpc.c')
-rw-r--r--sys/cam/ctl/ctl_tpc.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/cam/ctl/ctl_tpc.c b/sys/cam/ctl/ctl_tpc.c
index 4197287dbdfa..06263b365fbc 100644
--- a/sys/cam/ctl/ctl_tpc.c
+++ b/sys/cam/ctl/ctl_tpc.c
@@ -942,14 +942,14 @@ tpc_process(struct tpc_list *list)
done:
//printf("ZZZ done\n");
+ free(list->params, M_CTL);
+ list->params = NULL;
mtx_lock(&lun->lun_lock);
if ((list->flags & EC_LIST_ID_USAGE_MASK) == EC_LIST_ID_USAGE_NONE) {
TAILQ_REMOVE(&lun->tpc_lists, list, links);
free(list, M_CTL);
} else {
list->completed = 1;
- free(list->params, M_CTL);
- list->params = NULL;
list->sense_data = ctsio->sense_data;
list->sense_len = ctsio->sense_len;
list->scsi_status = ctsio->scsi_status;