summaryrefslogtreecommitdiff
path: root/usr.sbin/bhyve/pci_xhci.c
diff options
context:
space:
mode:
authorMarcelo Araujo <araujo@FreeBSD.org>2018-11-02 08:01:42 +0000
committerMarcelo Araujo <araujo@FreeBSD.org>2018-11-02 08:01:42 +0000
commit93670f79d77064940a76bba538302fe48bc3900d (patch)
tree8f4cbcbacd672504320d4282deb360eec44f3c3a /usr.sbin/bhyve/pci_xhci.c
parent6c8dae3cbaf13c9d8083c9e1cbf42489662af899 (diff)
downloadsrc-test2-93670f79d77064940a76bba538302fe48bc3900d.tar.gz
src-test2-93670f79d77064940a76bba538302fe48bc3900d.zip
Notes
Diffstat (limited to 'usr.sbin/bhyve/pci_xhci.c')
-rw-r--r--usr.sbin/bhyve/pci_xhci.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/usr.sbin/bhyve/pci_xhci.c b/usr.sbin/bhyve/pci_xhci.c
index 6a92491de869..3c0a798a0112 100644
--- a/usr.sbin/bhyve/pci_xhci.c
+++ b/usr.sbin/bhyve/pci_xhci.c
@@ -2700,6 +2700,8 @@ pci_xhci_parse_opts(struct pci_xhci_softc *sc, char *opts)
sc->ndevices++;
}
+ if (uopt != NULL)
+ free(uopt);
portsfinal:
sc->portregs = calloc(XHCI_MAX_DEVS, sizeof(struct pci_xhci_portregs));
@@ -2729,6 +2731,7 @@ done:
free(devices);
}
}
+ free(uopt);
return (sc->ndevices);
}