Artur Wojcik: Fix for NULL pointer dereference defect.
Martin F. Krafft
madduck at alioth.debian.org
Wed Jan 27 02:03:52 UTC 2010
Module: mdadm
Branch: upstream
Commit: d362da3dfef78f016690e677052b20a163e65236
URL: http://git.debian.org/?p=pkg-mdadm/mdadm.git;a=commit;h=d362da3dfef78f016690e677052b20a163e65236
Author: Artur Wojcik <artur.wojcik at intel.com>
Date: Thu Dec 10 12:03:40 2009 -0700
Fix for NULL pointer dereference defect.
Pointer 'disk' returned from call to function '_get_imsm_disk' at line
700 may be NULL and will be dereferenced at line 710.
Signed-off-by: Artur Wojcik <artur.wojcik at intel.com>
Signed-off-by: Dan Williams <dan.j.williams at intel.com>
---
super-intel.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/super-intel.c b/super-intel.c
index a2acaaf..da753a0 100644
--- a/super-intel.c
+++ b/super-intel.c
@@ -703,7 +703,7 @@ static void print_imsm_disk(struct imsm_super *mpb, int index, __u32 reserved)
char str[MAX_RAID_SERIAL_LEN + 1];
__u64 sz;
- if (index < 0)
+ if (index < 0 || !disk)
return;
printf("\n");
More information about the pkg-mdadm-commits
mailing list