[iso] fix a possible buffer overflow in GetGrubVersion()

* Also increase the size for "probably a flash drive if under" from 32 GB to 128 GB.
This commit is contained in:
Pete Batard 2023-04-01 14:39:25 +02:00
parent ee6c907415
commit 9285313f28
No known key found for this signature in database
GPG key ID: 38E0CF5E69EDD671
3 changed files with 16 additions and 12 deletions

View file

@ -462,7 +462,7 @@ int IsHDD(DWORD DriveIndex, uint16_t vid, uint16_t pid, const char* strid)
score_list[score_list_size] = 15;
score += score_list[score_list_size++];
}
} else if (drive_size < 32 * GB) {
} else if (drive_size < 128 * GB) {
score_list[score_list_size] = -15;
score += score_list[score_list_size++];
}