- runcommandwithstatus("/usr/bin/downloadsource.sh",
- title, _("Downloading installation image..."), logfile);
-
- if ((handle = fopen("/tmp/source_device", "r")) == NULL) {
- errorbox(_("Download error"));
+ snprintf(commandstring, sizeof(commandstring), "/usr/bin/downloadsource.sh %s", SOURCE_TEMPFILE);
+ runcommandwithstatus(commandstring, title, _("Downloading installation image..."), logfile);
+
+ FILE* f = fopen(SOURCE_TEMPFILE, "r");
+ if (f) {
+ sourcedrive = SOURCE_TEMPFILE;
+ fclose(f);
+ } else {
+ errorbox(_("The installation image could not be downloaded."));