summaryrefslogtreecommitdiffstats
path: root/mdk-stage1/directory.c
diff options
context:
space:
mode:
authorOlivier Blin <oblin@mandriva.org>2004-07-13 08:32:56 +0000
committerOlivier Blin <oblin@mandriva.org>2004-07-13 08:32:56 +0000
commitcc4117275a36d997ae9b937c82b550b7d093559d (patch)
treeff8cedfcc1b0332eae510ca27b373dd7d3c9dd97 /mdk-stage1/directory.c
parent4903c60de2d977855024ff1bc5501f514b4aa2e6 (diff)
downloaddrakx-cc4117275a36d997ae9b937c82b550b7d093559d.tar
drakx-cc4117275a36d997ae9b937c82b550b7d093559d.tar.gz
drakx-cc4117275a36d997ae9b937c82b550b7d093559d.tar.bz2
drakx-cc4117275a36d997ae9b937c82b550b7d093559d.tar.xz
drakx-cc4117275a36d997ae9b937c82b550b7d093559d.zip
don't forget to umount ISO images
Diffstat (limited to 'mdk-stage1/directory.c')
-rw-r--r--mdk-stage1/directory.c12
1 files changed, 9 insertions, 3 deletions
diff --git a/mdk-stage1/directory.c b/mdk-stage1/directory.c
index 0ca78397a..e322c8379 100644
--- a/mdk-stage1/directory.c
+++ b/mdk-stage1/directory.c
@@ -92,7 +92,7 @@ enum return_type try_with_directory(char *directory, char *method_live, char *me
stage2_isos[stage2_iso_number++] = strdup(*file);
}
- umount(IMAGE_LOCATION);
+ umount(IMAGE_LOCATION);
del_loop(loopdev);
}
@@ -150,11 +150,13 @@ enum return_type try_with_directory(char *directory, char *method_live, char *me
"(I need the subdirectory " RAMDISK_LOCATION ")\n"
"Here's a short extract of the files in the directory:\n"
"%s", extract_list_directory(IMAGE_LOCATION));
+ umount(IMAGE_LOCATION);
del_loop(loopdev);
return RETURN_ERROR;
}
if (load_ramdisk() != RETURN_OK) {
stg1_error_message("Could not load program into memory.");
+ umount(IMAGE_LOCATION);
del_loop(loopdev);
return RETURN_ERROR;
}
@@ -171,6 +173,7 @@ enum return_type try_with_directory(char *directory, char *method_live, char *me
"(I need the subdirectory " LIVE_LOCATION ")\n"
"Here's a short extract of the files in the directory:\n"
"%s", extract_list_directory(IMAGE_LOCATION));
+ umount(IMAGE_LOCATION);
del_loop(loopdev);
return RETURN_ERROR;
}
@@ -179,6 +182,7 @@ enum return_type try_with_directory(char *directory, char *method_live, char *me
stg1_error_message("The " DISTRIB_NAME " Distribution seems to be copied on a Windows partition. "
"You need more memory to perform an installation from a Windows partition. "
"Another solution if to copy the " DISTRIB_NAME " Distribution on a Linux partition.");
+ umount(IMAGE_LOCATION);
del_loop(loopdev);
return RETURN_ERROR;
}
@@ -186,8 +190,10 @@ enum return_type try_with_directory(char *directory, char *method_live, char *me
}
#endif
- if (IS_RESCUE)
- del_loop(loopdev);
+ if (IS_RESCUE) {
+ umount(IMAGE_LOCATION);
+ del_loop(loopdev);
+ }
return RETURN_OK;
}