From 088b6a686d887e02739c34736520715f737fe0c5 Mon Sep 17 00:00:00 2001 From: Olivier Blin Date: Thu, 12 Feb 2009 10:40:57 +0000 Subject: try to use arch-prefixed location for automatic disk installs --- mdk-stage1/disk.c | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) (limited to 'mdk-stage1/disk.c') diff --git a/mdk-stage1/disk.c b/mdk-stage1/disk.c index acdc1efaf..d8f26d3a6 100644 --- a/mdk-stage1/disk.c +++ b/mdk-stage1/disk.c @@ -48,12 +48,15 @@ static enum return_type try_automatic_with_partition(char *dev) { wait_message("Trying to access " DISTRIB_NAME " disk (partition %s)", dev); mounted = !try_mount(dev, MEDIA_LOCATION); remove_wait_message(); - if (mounted && !access(MEDIA_LOCATION "/" COMPRESSED_LOCATION_REL, R_OK)) { - results = try_with_directory(MEDIA_LOCATION, "disk", "disk-iso"); - if (results == RETURN_OK) { - if (!KEEP_MOUNTED) - umount(MEDIA_LOCATION); - return RETURN_OK; + if (mounted) { + create_IMAGE_LOCATION(MEDIA_LOCATION); + if (image_has_stage2()) { + results = try_with_directory(MEDIA_LOCATION, "disk", "disk-iso"); + if (results == RETURN_OK) { + if (!KEEP_MOUNTED) + umount(MEDIA_LOCATION); + return RETURN_OK; + } } } if (mounted) -- cgit v1.2.1