From b12399dd1e6beaa950e8d53b11e3a41648693c29 Mon Sep 17 00:00:00 2001 From: Guillaume Cottenceau Date: Thu, 11 Jan 2001 22:25:49 +0000 Subject: act nicely when no partitions are found on some disk --- mdk-stage1/disk.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'mdk-stage1/disk.c') diff --git a/mdk-stage1/disk.c b/mdk-stage1/disk.c index b092604e4..ac38f82e0 100644 --- a/mdk-stage1/disk.c +++ b/mdk-stage1/disk.c @@ -96,6 +96,11 @@ static enum return_type try_with_device(char *dev_name) parts[i] = NULL; fclose(f); + if (parts[0] == NULL) { + error_message("No partitions found."); + return RETURN_ERROR; + } + results = ask_from_list_comments("Please choose the partition where is copied the " DISTRIB_NAME " Distribution.", parts, parts_comments, &choice); if (results != RETURN_OK) -- cgit v1.2.1