[misc] pocketful of enhancement and fixes - part 1

* Add a cheat mode for VMWare disk detection
* Add a cheat mode to delete the rufus_files directory
* Don't attempt a grub2 download in case we couldn't read the version
* Don't use a shared message buffer between info and status and also
  use a more logical handling of low pri/high pri and timeout
* Also fix unwanted selection of info text on restore from minimize
* Also fix the localization generation and add more messages
This commit is contained in:
Pete Batard 2015-01-08 00:22:56 +00:00
parent c56a1c87de
commit 2e817ae944
11 changed files with 124 additions and 58 deletions

View file

@ -755,7 +755,7 @@ out:
}
if (iso_report.has_grub2) {
// In case we have a GRUB2 based iso, we extract boot/grub/i386-pc/normal.mod to parse its version
strcpy(iso_report.grub2_version, "unknown");
iso_report.grub2_version[0] = 0;
if ((GetTempPathU(sizeof(path), path) != 0) && (GetTempFileNameU(path, APPLICATION_NAME, 0, path) != 0)) {
size = (size_t)ExtractISOFile(src_iso, "boot/grub/i386-pc/normal.mod", path, FILE_ATTRIBUTE_NORMAL);
buf = (char*)calloc(size, 1);
@ -770,7 +770,10 @@ out:
free(buf);
_unlink(path);
}
uprintf("Detected Grub version: %s", iso_report.grub2_version);
if (iso_report.grub2_version[0] != 0)
uprintf("Detected Grub version: %s", iso_report.grub2_version);
else
uprintf("Could not detect Grub2 version");
}
StrArrayDestroy(&config_path);
StrArrayDestroy(&isolinux_path);