From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:59940) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RLZQe-0005Kw-Rn for qemu-devel@nongnu.org; Wed, 02 Nov 2011 07:56:25 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RLZQd-0006bz-Q5 for qemu-devel@nongnu.org; Wed, 02 Nov 2011 07:56:24 -0400 Received: from mx1.redhat.com ([209.132.183.28]:36746) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RLZQd-0006bi-GP for qemu-devel@nongnu.org; Wed, 02 Nov 2011 07:56:23 -0400 From: Gerd Hoffmann Date: Wed, 2 Nov 2011 12:56:14 +0100 Message-Id: <1320234974-15318-1-git-send-email-kraxel@redhat.com> Subject: [Qemu-devel] [PATCH] intel-hda: fix stream search List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: marcandre.lureau@gmail.com, Gerd Hoffmann commit ba43d28916c4f51c19bd7366089155ce81bee058 introduces a bug: The stream-not-found case doesn't error out any more, instead the code silently uses the first stream. Fix it. Signed-off-by: Gerd Hoffmann --- hw/intel-hda.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/hw/intel-hda.c b/hw/intel-hda.c index 675b659..b7ec36d 100644 --- a/hw/intel-hda.c +++ b/hw/intel-hda.c @@ -401,7 +401,7 @@ static bool intel_hda_xfer(HDACodecDevice *dev, uint32_t stnr, bool output, break; } } - if (st == NULL) { + if (s == 4) { return false; } if (st->bpl == NULL) { -- 1.7.1