mirror of
https://github.com/opnsense/src.git
synced 2026-06-09 00:32:25 -04:00
If bus_generic_susped returns an error, devlist is not freed. Free it.
Submitted by: Ted Unangst (using the Coverity Prevent analysis tool)
This commit is contained in:
parent
e0251bbbe7
commit
463ec0ac87
1 changed files with 3 additions and 1 deletions
|
|
@ -1059,8 +1059,10 @@ pci_suspend(device_t dev)
|
|||
|
||||
/* Suspend devices before potentially powering them down. */
|
||||
error = bus_generic_suspend(dev);
|
||||
if (error)
|
||||
if (error) {
|
||||
free(devlist, M_TEMP);
|
||||
return (error);
|
||||
}
|
||||
|
||||
/*
|
||||
* Always set the device to D3. If ACPI suggests a different
|
||||
|
|
|
|||
Loading…
Reference in a new issue