Page 1 of 1
Why the Directory Entry has 64 byte long?
Posted: Sat Oct 30, 2004 6:27 pm
by iamxiaohan
hi,
I read some paper said "the directory entry has only 32 byte long". But I found that the directory entry has 64 byte long!
when i create a file, there are 64 byte data will be added into the Root Directory and only last 32 byte of the 64 byte looks like the true directory entry. what's the early 32 byte?
can you help me?
thank you very much!
Re:Why the Directory Entry has 64 byte long?
Posted: Sat Oct 30, 2004 7:26 pm
by Curufir
Well you haven't been very specific about what you're doing, so a lot of guesswork is required.
Let's assume you're using some kind of FAT filesystem. ( That guess is based on you mentioning 32 bytes. FAT uses 32-bit entries ).
It's possible that you've created a file/directory with a long filename (IE not 8.3 format). FAT uses extra directory entries (Marked hidden) to contain long filenames (This is a horrible hack by MS I might add).
Another possibility is that you're looking inside the directory, not in the root directory. All directories except the root directory will contain at least two entries . and .. that refer to the directory and its parent (These are created automatically when the directory is created).
***
That's just guesswork though. We really need more information if you want us to help you.
Re:Why the Directory Entry has 64 byte long?
Posted: Sat Oct 30, 2004 7:47 pm
by iamxiaohan
thank you for your reply
I'll give you more information.
I use FAT12 File System. And i think the 0x2600 is the start address of the root directory.
then I create a file named "test.bat" in the A: driver.
then i fonud the windows98 added 64 byte data into the root directory region. I think win98 should only added 32 byte data.I fond that, the early 32 byte of the 64 byte is "0x41 0x60 0x00 0x6c 0x00 0x6F 0x00...." and the last 32 byte is "0x46 0x4c 0x4f ....". I think the last one is the true driectory entry. but what's the early 32 byte? that's my problem~~
i need your help! thank you very much!
Re:Why the Directory Entry has 64 byte long?
Posted: Sun Oct 31, 2004 8:20 pm
by iamxiaohan
haha, i know what's the problem. the early entry is LFN entry.
thank you all the same! ;P
Re:Why the Directory Entry has 64 byte long?
Posted: Sun Oct 31, 2004 11:51 pm
by Candy
Thank you for telling us you're using Windows XP
it's the only one that always adds long file names, even if they're not necessary... Assuming it isn't necessary here, which I can't tell from the name itself...
Re:Why the Directory Entry has 64 byte long?
Posted: Mon Nov 01, 2004 4:37 am
by smiddy
I have some Win98 formated disks that have the long file name stuff too. You can get information on long file names
http://www.osdever.net/documents/LongFileName.pdf?the_id=39. I hope this helps...