Module Name: src
Committed By: nat
Date: Sun Jan 15 00:04:02 UTC 2017
Modified Files:
src/sys/dev: audio.c
Log Message:
Forgot not to decrement sc_opens on unsuccessful open.
To generate a diff of this commit:
cvs rdiff -u -r1.290 -r1.291 src/sys/dev/audio.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/sys/dev/audio.c
diff -u src/sys/dev/audio.c:1.290 src/sys/dev/audio.c:1.291
--- src/sys/dev/audio.c:1.290 Sat Jan 14 20:05:37 2017
+++ src/sys/dev/audio.c Sun Jan 15 00:04:01 2017
@@ -1,4 +1,4 @@
-/* $NetBSD: audio.c,v 1.290 2017/01/14 20:05:37 nat Exp $ */
+/* $NetBSD: audio.c,v 1.291 2017/01/15 00:04:01 nat Exp $ */
/*-
* Copyright (c) 2016 Nathanial Sloss <[email protected]>
@@ -148,7 +148,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: audio.c,v 1.290 2017/01/14 20:05:37 nat Exp $");
+__KERNEL_RCSID(0, "$NetBSD: audio.c,v 1.291 2017/01/15 00:04:01 nat Exp $");
#include "audio.h"
#if NAUDIO > 0
@@ -2027,11 +2027,6 @@ bad:
vc->sc_nrfilters = 0;
if (hw->close != NULL && sc->sc_opens == 0)
hw->close(sc->hw_hdl);
- if (flags & FREAD)
- sc->sc_recopens--;
- sc->sc_opens--;
- sc->sc_audiopid[n].pid = -1;
- sc->sc_despid[n].pid = -1;
mutex_exit(sc->sc_lock);
audio_free_ring(sc, &vc->sc_mpr);
audio_free_ring(sc, &vc->sc_mrr);