From: linux@audioscience.com
To: patch@alsa-project.org
Cc: Eliot Blennerhassett <eblennerhassett@audioscience.com>,
alsa-devel@alsa-project.org
Subject: [PATCH - asihpi 5/6] Avoid null pointer dereference.
Date: Fri, 22 Aug 2008 17:26:32 +1200 [thread overview]
Message-ID: <1219382793-21272-2-git-send-email-linux@audioscience.com> (raw)
In-Reply-To: <1219382793-21272-1-git-send-email-linux@audioscience.com>
From: Eliot Blennerhassett <eblennerhassett@audioscience.com>
Signed-off-by: Eliot Blennerhassett <eblennerhassett@audioscience.com>
diff --git a/pci/asihpi/hpi6205.c b/pci/asihpi/hpi6205.c
index daa359d..1654070 100644
--- a/pci/asihpi/hpi6205.c
+++ b/pci/asihpi/hpi6205.c
@@ -2126,6 +2126,9 @@ static short Hpi6205_TransferData(
u32 dwTimeOut, dwTemp2;
struct bus_master_interface *interface = pHw6205->pInterfaceBuffer;
+ if (!pData)
+ return HPI_ERROR_INVALID_DATA_TRANSFER;
+
dwDataSize &= ~3L; /* round dwDataSize down to nearest 4 bytes */
/* make sure state is IDLE */
--
1.5.4.3
next prev parent reply other threads:[~2008-08-22 5:26 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-08-22 5:26 [PATCH - asihpi 4/6] Mem buffer alloc inside adapter mutex linux
2008-08-22 5:26 ` linux [this message]
2008-08-22 5:26 ` [PATCH - asihpi 6/6] Return from timer func if XRUN. Avoids read/write of reset stream linux
2008-08-22 6:46 ` [PATCH - asihpi 4/6] Mem buffer alloc inside adapter mutex Takashi Iwai
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1219382793-21272-2-git-send-email-linux@audioscience.com \
--to=linux@audioscience.com \
--cc=alsa-devel@alsa-project.org \
--cc=eblennerhassett@audioscience.com \
--cc=patch@alsa-project.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.