HomeFreeBSD

sound: Simplify vchan_create() error paths

Description

sound: Simplify vchan_create() error paths

Instead of checking the value of "ret" multiple times, just set a goto
label and jump there immediately in case of an error.

While here, remove a redundant assignment to "d".

Sponsored by: The FreeBSD Foundation
MFC after: 2 days
Reviewed by: dev_submerge.ch, markj, emaste
Differential Revision: https://reviews.freebsd.org/D46833

(cherry picked from commit 3cab66d12d439357b948093756ca1af87967c8cc)

Details

Provenance
christosAuthored on Oct 18 2024, 8:40 AM
Reviewer
dev_submerge.ch
Differential Revision
D46833: sound: Simplify vchan_create() error paths
Parents
rGebdf08844534: sound: Retire SND_MAXHWCHAN
Branches
Unknown
Tags
Unknown