+ fat-fix-bug-in-enforcing-long-file-name-length.patch added to -mm tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The patch titled
     Subject: fat: fix bug in enforcing Long File Name length
has been added to the -mm tree.  Its filename is
     fat-fix-bug-in-enforcing-long-file-name-length.patch

Before you just go and hit "reply", please:
   a) Consider who else should be cc'ed
   b) Prefer to cc a suitable mailing list as well
   c) Ideally: find the original patch on the mailing list and do a
      reply-to-all to that, adding suitable additional cc's

*** Remember to use Documentation/SubmitChecklist when testing your code ***

The -mm tree is included into linux-next and is updated
there every 3-4 working days

------------------------------------------------------
From: Namjae Jeon <linkinjeon@xxxxxxxxx>
Subject: fat: fix bug in enforcing Long File Name length

Since '*outlen' is initialized to zero, it is currently possible to create
a filename of length (FAT_LFN_LEN + 1) when utf8 is not enabled.  To
enforce the FAT_LFN_LEN limit, we must perform one less iteration.

Signed-off-by: Namjae Jeon <linkinjeon@xxxxxxxxx>
Signed-off-by: Ravishankar N <cyberax82@xxxxxxxxx>
Acked-by: OGAWA Hirofumi <hirofumi@xxxxxxxxxxxxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
---

 fs/fat/namei_vfat.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff -puN fs/fat/namei_vfat.c~fat-fix-bug-in-enforcing-long-file-name-length fs/fat/namei_vfat.c
--- a/fs/fat/namei_vfat.c~fat-fix-bug-in-enforcing-long-file-name-length
+++ a/fs/fat/namei_vfat.c
@@ -522,7 +522,7 @@ xlate_to_uni(const unsigned char *name, 
 		op = &outname[*outlen * sizeof(wchar_t)];
 	} else {
 		for (i = 0, ip = name, op = outname, *outlen = 0;
-			 i < len && *outlen <= FAT_LFN_LEN;
+			 i < len && *outlen < FAT_LFN_LEN;
 			 *outlen += 1) {
 			if (escape && (*ip == ':')) {
 				if (i > len - 5)
_
Subject: Subject: fat: fix bug in enforcing Long File Name length

Patches currently in -mm which might be from linkinjeon@xxxxxxxxx are

linux-next.patch
fat-clean-up-xlate_to_uni.patch
fat-fix-bug-in-enforcing-long-file-name-length.patch

--
To unsubscribe from this list: send the line "unsubscribe mm-commits" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Kernel Newbies FAQ]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Photo]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux