1
0
Fork 0

fat: reset VFAT short alias checksum on first match

The VFAT short alias checksum read from a long file name is only overwritten
when another long file name appears in a directory list. Until then it renders
short file names invisible that have the same checksum. Reset the checksum on
first match.

Signed-off-by: Sergei Shtylyov <sshtylyov@ru.mvista.com>
Signed-off-by: Martin Mueller <martin.mueller5@de.bosch.com>
utp
Sergei Shtylyov 2012-01-02 06:54:29 +00:00 committed by Wolfgang Denk
parent 2620368a61
commit bf34e7d952
1 changed files with 2 additions and 0 deletions

View File

@ -633,6 +633,7 @@ static dir_entry *get_dentfromdir (fsdata *mydata, int startsect,
}
#ifdef CONFIG_SUPPORT_VFAT
if (dols && mkcksum(dentptr->name) == prevcksum) {
prevcksum = 0xffff;
dentptr++;
continue;
}
@ -963,6 +964,7 @@ do_fat_read (const char *filename, void *buffer, unsigned long maxsize,
#ifdef CONFIG_SUPPORT_VFAT
else if (dols == LS_ROOT &&
mkcksum(dentptr->name) == prevcksum) {
prevcksum = 0xffff;
dentptr++;
continue;
}