mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-11 23:24:22 -04:00
exfat: Set the unused characters of FileName field to the value 0000h
Some fsck tool complain that padding part of the FileName field is not set to the value 0000h. So let's maintain filesystem cleaner, as exfat's spec. recommendation. Signed-off-by: Hyeongseok.Kim <Hyeongseok@gmail.com> Reviewed-by: Sungjong Seo <sj1557.seo@samsung.com> Signed-off-by: Namjae Jeon <namjae.jeon@samsung.com> Git-commit: 4ba6ccd695f5ed3ae851e59b443b757bbe4557fe Git-repo: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git Signed-off-by: lixiang <lixiang@codeaurora.org>
This commit is contained in:
parent
a9516936e5
commit
e79cb8c29f
1 changed files with 6 additions and 4 deletions
|
|
@ -425,10 +425,12 @@ static void exfat_init_name_entry(struct exfat_dentry *ep,
|
|||
ep->dentry.name.flags = 0x0;
|
||||
|
||||
for (i = 0; i < EXFAT_FILE_NAME_LEN; i++) {
|
||||
ep->dentry.name.unicode_0_14[i] = cpu_to_le16(*uniname);
|
||||
if (*uniname == 0x0)
|
||||
break;
|
||||
uniname++;
|
||||
if (*uniname != 0x0) {
|
||||
ep->dentry.name.unicode_0_14[i] = cpu_to_le16(*uniname);
|
||||
uniname++;
|
||||
} else {
|
||||
ep->dentry.name.unicode_0_14[i] = 0x0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue