Re: VFAT: Can't create file named 'aux.h'?

From: OGAWA Hirofumi
Date: Thu Mar 23 2006 - 09:53:35 EST


René Scharfe <rene.scharfe@xxxxxxxxxxxxxx> writes:

> OGAWA Hirofumi schrieb:
>> Looks like we get a good reason to kill strange reserved names in vfat
>> (and msdos too?).
>>
>> Could you/anyone check what shortname is used for "AUX" if it is created
>> in cmd.exe?
>
> on Windows XP Home SP2 I did:
>
> mkdir d:\test
> cd /d d:\test
> echo 1 > \\?\d:\test\aux
> echo 2 > \\?\d:\test\nul
> echo 3 > \\?\d:\test\nul.x
> echo 4 > \\?\d:\test\nul.longext
> echo 5 > \\?\d:\test\...
> echo 6 > "\\?\d:\test\[];,+="
> echo 7 > "\\?\d:\test\ "
> dir /x > a.txt
>
> And here's the contents of a.txt:
>
> --- snip! ---
> Datenträger in Laufwerk D: ist 53_00_00
> Volumeseriennummer: 1002-884F
>
> Verzeichnis von D:\test
>
> 23.03.2006 12:21 <DIR> .
> 23.03.2006 12:21 <DIR> ..
> 23.03.2006 12:21 4 0103~1
> 23.03.2006 12:21 4 7154~1 ...
> 23.03.2006 12:21 0 a.txt
> 23.03.2006 12:21 4 aux
> 23.03.2006 12:21 4 nul
> 23.03.2006 12:21 4 NUL~1.LON nul.longext
> 23.03.2006 12:21 4 nul.x
> 23.03.2006 12:21 4 ______~1 [];,+=
> 8 Datei(en) 28 Bytes
> 2 Verzeichnis(se), 31.506.370.560 Bytes frei
> --- snip! ---
>
> So, no shortname is created for aux on my machine.

Thanks, Phillip and Rene.

It seems the shortname. Because "a.txt" is using same form, and
"no shortname" is meaning a "broken directory entry" in fat spec.

> Of course that doesn't prevent us from creating one in vfat, right?

Yes. We would not need special case for devices.

I'll remove reserved names from vfat/msdos, because many OSes/commands
(even Windows) creates it.

Thanks.
--
OGAWA Hirofumi <hirofumi@xxxxxxxxxxxxxxxxxx>
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/