svn commit: r267754 - stable/10/sys/cam/ctl
Alexander Motin
mav at FreeBSD.org
Sun Jun 22 21:28:05 UTC 2014
Author: mav
Date: Sun Jun 22 21:28:05 2014
New Revision: 267754
URL: http://svnweb.freebsd.org/changeset/base/267754
Log:
MFC r267429:
Fix some leaks on LUN creation error.
Modified:
stable/10/sys/cam/ctl/ctl_backend_block.c
Directory Properties:
stable/10/ (props changed)
Modified: stable/10/sys/cam/ctl/ctl_backend_block.c
==============================================================================
--- stable/10/sys/cam/ctl/ctl_backend_block.c Sun Jun 22 21:26:46 2014 (r267753)
+++ stable/10/sys/cam/ctl/ctl_backend_block.c Sun Jun 22 21:28:05 2014 (r267754)
@@ -2115,9 +2115,14 @@ ctl_be_block_create(struct ctl_be_block_
bailout_error:
req->status = CTL_LUN_ERROR;
+ if (be_lun->io_taskqueue != NULL)
+ taskqueue_free(be_lun->io_taskqueue);
ctl_be_block_close(be_lun);
-
- free(be_lun->dev_path, M_CTLBLK);
+ if (be_lun->dev_path != NULL)
+ free(be_lun->dev_path, M_CTLBLK);
+ if (be_lun->lun_zone != NULL)
+ uma_zdestroy(be_lun->lun_zone);
+ mtx_destroy(&be_lun->lock);
free(be_lun, M_CTLBLK);
return (retval);
More information about the svn-src-all
mailing list