]> git.ipfire.org Git - thirdparty/grub.git/commit
fs/ntfs: Correct regression with run list calculation
authorAndrew Hamilton <adhamilt@gmail.com>
Thu, 22 May 2025 03:20:37 +0000 (22:20 -0500)
committerDaniel Kiper <daniel.kiper@oracle.com>
Thu, 29 May 2025 13:45:24 +0000 (15:45 +0200)
commit0e1762c8a0c2a952e99caab9e3ffb64816799bcf
treef9f51fdeb9fab48d658414ed1812f1744609ce86
parentbe303f8c1859b17e0dbee88cb7c8490058c150f4
fs/ntfs: Correct regression with run list calculation

Correct ntfs_test test failures around attempting to validate attribute
run list values. The calculation was incorrect for the "curr" variable.
With previous calculation, some file systems would fail validation
despite being well-formed and valid. This was caused by incrementing
"curr" by min_size which included both the (already accounted for)
min_size as well as the size of the run list. Correct by making a new
variable "run_size" to denote the current run list size to increment
both "curr" and "min_size" separately.

Fixes: 067b6d225 (fs/ntfs: Implement attribute verification)
Signed-off-by: Andrew Hamilton <adhamilt@gmail.com>
Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com>
grub-core/fs/ntfs.c