[PATCH] segfault in imsm create with wrong arguments
am 12.12.2010 12:33:55 von Luca Berra--HlL+5n6rz5pIUxbD
Content-Type: text/plain; charset=iso-8859-1; format=flowed
Content-Disposition: inline
When calling mdadm -C --metadata=imsm -l 1 /dev/sd..
mdadm segfaults in default_chunk_imsm()
above syntax is incorrect, but mdadm should error instead of segfaulting
--
Luca Berra -- bluca@comedia.it
--HlL+5n6rz5pIUxbD
Content-Type: text/plain; charset=iso-8859-1
Content-Disposition: attachment; filename="mdadm-3.1.4-imsm-create-segfault.patch"
When calling mdadm -C --metadata=imsm -l 1 /dev/sd..
mdadm segfaults in default_chunk_imsm()
above syntax is incorrect, but mdadm should error instead of segfaulting
Signed-off-by: Luca Berra
diff -p -up mdadm-3.1.4/super-intel.c.bluca mdadm-3.1.4/super-intel.c
--- mdadm-3.1.4/super-intel.c.bluca 2010-08-26 02:24:16.000000000 +0000
+++ mdadm-3.1.4/super-intel.c 2010-12-12 11:13:00.024371004 +0000
@@ -4119,7 +4119,7 @@ static int default_chunk_imsm(struct sup
{
struct intel_super *super = st->sb;
- if (!super->orom)
+ if (!super || !super->orom)
return 0;
return imsm_orom_default_chunk(super->orom);
--HlL+5n6rz5pIUxbD--
--
To unsubscribe from this list: send the line "unsubscribe linux-raid" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html