NVR and Intel Flash functions now don't free the file name pointers until after all file I/O is done.

This commit is contained in:
OBattler
2017-06-22 18:38:36 +02:00
parent 21b3b6d51d
commit 08363e5ec2
2 changed files with 15 additions and 9 deletions

View File

@@ -190,9 +190,6 @@ void *intel_flash_init(uint8_t type)
wcscpy(flash_path, flash_name);
free(flash_name);
free(model_name);
pclog_w(L"Flash path: %s\n", flash_name);
flash->flash_id = (type & FLASH_IS_BXB) ? 0x95 : 0x94;
@@ -264,6 +261,9 @@ void *intel_flash_init(uint8_t type)
fclose(f);
}
free(flash_name);
free(model_name);
return flash;
}