When not all attributes are supported (attributes incompatibility) function container_content_imsm returns NULL pointer. In this case mdadm should immediately exit with error to prevent using null "list" pointer. Signed-off-by: Lukasz Dorau <lukasz.dorau@xxxxxxxxx> --- Incremental.c | 5 +++++ 1 files changed, 5 insertions(+), 0 deletions(-) diff --git a/Incremental.c b/Incremental.c index 951c2a0..deace7d 100644 --- a/Incremental.c +++ b/Incremental.c @@ -1460,6 +1460,11 @@ static int Incremental_container(struct supertype *st, char *devname, trustworthy = FOREIGN; list = st->ss->container_content(st, NULL); + if (!list) { + fprintf(stderr, Name ": Cannot get container content. " + "Array cannot be assembled.\n"); + return 2; + } if (map_lock(&map)) fprintf(stderr, Name ": failed to get exclusive lock on " "mapfile\n"); --------------------------------------------------------------------- Intel Technology Poland sp. z o.o. z siedziba w Gdansku ul. Slowackiego 173 80-298 Gdansk Sad Rejonowy Gdansk Polnoc w Gdansku, VII Wydzial Gospodarczy Krajowego Rejestru Sadowego, numer KRS 101882 NIP 957-07-52-316 Kapital zakladowy 200.000 zl This e-mail and any attachments may contain confidential material for the sole use of the intended recipient(s). Any review or distribution by others is strictly prohibited. If you are not the intended recipient, please contact the sender and delete all copies. ��.n��������+%������w��{.n�����{����w��ܨ}���Ơz�j:+v�����w����ޙ��&�)ߡ�a����z�ޗ���ݢj��w�f