-
Notifications
You must be signed in to change notification settings - Fork 936
Open
Labels
needs fixwe know what is wrongwe know what is wrong
Description
The function uses lfs_bd_cmp() which, from what I understand, compares data on disk with an arbitrary data passed as argument, and returns:
LFS_CMP_LT- the data on disk is less than the arbitrary dataLFS_CMP_GT- the data on disk is greater than the arbitrary dataLFS_CMP_EQ- the data on disk and the arbitrary data are equal
If the function returns LFS_CMP_EQ, we perform an additional comparison:
if (name->size != lfs_tag_size(tag)) {
return (name->size < lfs_tag_size(tag)) ? LFS_CMP_LT : LFS_CMP_GT;
}
This comparison looks suspicious because it returns LFS_CMP_LT is the arbitrary data (not the data on disk) is shorter than the data on disk. Maybe it was intended this way but just in case decided to report.
geky
Metadata
Metadata
Assignees
Labels
needs fixwe know what is wrongwe know what is wrong