Skip to content

Commit

Permalink
Merge pull request #408 from 54shady/fix-task-free
Browse files Browse the repository at this point in the history
Manually set task to null after free to avoid double free issue
  • Loading branch information
sahlberg authored May 29, 2024
2 parents 9f7f2c9 + 9ec1215 commit dd94a21
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lib/scsi-lowlevel.c
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,8 @@ scsi_free_scsi_task(struct scsi_task *task)

free(task->datain.data);
free(task);
task->datain.data = NULL;
task = NULL;
}

struct scsi_task *
Expand Down

0 comments on commit dd94a21

Please sign in to comment.