[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <1415362715-24224-2-git-send-email-sudipm.mukherjee@gmail.com>
Date: Fri, 7 Nov 2014 17:48:35 +0530
From: Sudip Mukherjee <sudipm.mukherjee@...il.com>
To: Benjamin Romer <benjamin.romer@...sys.com>,
David Kershner <david.kershner@...sys.com>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>
Cc: Sudip Mukherjee <sudipm.mukherjee@...il.com>,
sparmaintainer@...sys.com, devel@...verdev.osuosl.org,
linux-kernel@...r.kernel.org
Subject: [PATCH 2/2] staging: unisys: dereferencing NULL pointer
we can reach the label Away in total five situation and in four of
of them pDevInfo is NULL. so we were basically dereferencing a NULL
pointer.
Signed-off-by: Sudip Mukherjee <sudip@...torindia.org>
---
drivers/staging/unisys/visorchipset/visorchipset_main.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/staging/unisys/visorchipset/visorchipset_main.c b/drivers/staging/unisys/visorchipset/visorchipset_main.c
index b5a0e46..c8f7bea 100644
--- a/drivers/staging/unisys/visorchipset/visorchipset_main.c
+++ b/drivers/staging/unisys/visorchipset/visorchipset_main.c
@@ -1298,7 +1298,8 @@ my_device_create(struct controlvm_message *inmsg)
POSTCODE_SEVERITY_INFO);
Away:
/* get the bus and devNo for DiagPool channel */
- if (is_diagpool_channel(pDevInfo->chan_info.channel_type_uuid)) {
+ if (pDevInfo &&
+ is_diagpool_channel(pDevInfo->chan_info.channel_type_uuid)) {
g_diagpoolBusNo = busNo;
g_diagpoolDevNo = devNo;
LOGINF("CONTROLVM_DEVICE_CREATE for DiagPool channel: busNo=%lu, devNo=%lu",
--
1.8.1.2
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists