diff options
author | imp <imp@FreeBSD.org> | 2008-08-23 18:27:10 +0000 |
---|---|---|
committer | imp <imp@FreeBSD.org> | 2008-08-23 18:27:10 +0000 |
commit | d95796acc990d45215e1c389657324a320cffd8a (patch) | |
tree | 5cd864313d01fd2a4178005876265bd8ce0dbfa8 | |
parent | 2eac2c424f8989e9605b40c2ed054ace66c8f0d6 (diff) | |
download | FreeBSD-src-d95796acc990d45215e1c389657324a320cffd8a.zip FreeBSD-src-d95796acc990d45215e1c389657324a320cffd8a.tar.gz |
Make sure that we handle errors in device_get_children correctly.
-rw-r--r-- | sys/dev/sound/pci/csa.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sys/dev/sound/pci/csa.c b/sys/dev/sound/pci/csa.c index 37a83c5..1499372 100644 --- a/sys/dev/sound/pci/csa.c +++ b/sys/dev/sound/pci/csa.c @@ -123,7 +123,8 @@ clkrun_hack(int run) for (i = 0, busp = pci_devices; i < pci_count; i++, busp++) { pci_childcount = 0; - device_get_children(*busp, &pci_children, &pci_childcount); + if (device_get_children(*busp, &pci_children, &pci_childcount)) + continue; for (j = 0, childp = pci_children; j < pci_childcount; j++, childp++) { if (pci_get_vendor(*childp) == 0x8086 && pci_get_device(*childp) == 0x7113) { port = (pci_read_config(*childp, 0x41, 1) << 8) + 0x10; |