mirror of
https://github.com/opnsense/src.git
synced 2026-06-11 09:41:03 -04:00
Don't touch a path after we've free'd it.
This commit is contained in:
parent
78c6551783
commit
5f14bb14e3
1 changed files with 5 additions and 4 deletions
|
|
@ -25,7 +25,7 @@
|
|||
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* $Id: scsi_target.c,v 1.8 1999/02/11 07:08:58 gibbs Exp $
|
||||
* $Id: scsi_target.c,v 1.9 1999/03/05 23:25:10 gibbs Exp $
|
||||
*/
|
||||
#include <stddef.h> /* For offsetof */
|
||||
|
||||
|
|
@ -638,9 +638,6 @@ targallocinstance(struct ioc_alloc_unit *alloc_unit)
|
|||
0, &cpi);
|
||||
|
||||
fail:
|
||||
if (free_path_on_return != 0)
|
||||
xpt_free_path(path);
|
||||
|
||||
switch (status) {
|
||||
case CAM_REQ_CMP:
|
||||
{
|
||||
|
|
@ -668,6 +665,10 @@ fail:
|
|||
error = ENODEV;
|
||||
break;
|
||||
}
|
||||
|
||||
if (free_path_on_return != 0)
|
||||
xpt_free_path(path);
|
||||
|
||||
return (error);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue