Star LFN

WARNING: This is far from being a complete program or documentation! This is a test release, use it with great care! Keep visiting the Star LFN homepage at http://sta.c64.org/starlfn.html for further releases.

Currently, the program has only experimental read-only support for VFAT, the way file names are stored by Windows 95/98! This means that, if VFAT support is enabled and you're writing files with long names onto the disk, the long names will be destroyed because the program can't write VFAT yet!

1. Introduction

This program is being designed to emulate the long file name functions that are present in the DOS shells of Windows 95/98 but under plain DOS 4.0 or above.

Because of the intensive disk access, a disk cache in write-back mode is highly recommended!

Programs similar to this one are the following:

There is a collection of such programs at http://sta.c64.org/lfnemu.html.

This program has initially been tested in a less risky environment (see the file access mode below), therefore its core is, probably, more robust and stable than any of the programs mentioned above. In this program, you can choose between two operational modes:

  1. File access: Long file names are stored in a hidden system file called "longname.dat" in each directory. This is the default mode, which is compatible with any operating system that has an able DOS shell because it involves significantly less hacking.

  2. Disk access: Long file names are stored in the disk area allocated for the directory. This is VFAT, the method Windows uses. In VFAT mode, this program supports uncompressed FAT12 and FAT16 partitions only and has been reported to fail on SCSI hard disks. WARNING: This mode is currently experimental and read-only!

Both modes work with ASSIGN'ed, JOIN'ed and SUBST'ed drives. Disk access mode refuses to show long file names on CD drives and network drives because these are stored with a completely different method, not VFAT.

The only way to exchange long file names between these two modes is putting the files into an archive, with a LFN-aware archiver, in one operational mode and extracting the files in the other mode.

2. Usage

The parameter syntax is the following:

STARLFN [-|/]<options>

<options>:

Without any options specified, the program will show usage information.

3. Technical background

The following INT 21h functions have already been implemented:

Fake INT 21h functions:

Some nice features worth mentioning:

The following features still have to be implemented:

Some features that do not follow the behavior of Windows 95/98 exactly and are unlikely to change (they would be either hard or useless to change):

Some problems that are solved when VFAT support is enabled:

Some problems that will be solved when VFAT support is finished:

A problem which is probably impossible to overcome is that the original DOS COMMAND.COM and external DOS commands cannot handle long file names so you won't be able to pass long file names as parameters to them. By the way, this is the reason why Caldera included a modified OpenDOS COMMAND.COM along with their long file name support program: to smarten up, at least, the internal DOS commands. A good solution is using 4DOS or booting DOS 7, which comes with Windows 95/98, because their internal DOS commands are also capable of using long file names, when available.

However, with this program and a DOS-based LFN-aware file manager, you'll be able to copy, rename, delete files and directories with long names under plain DOS. You may even backup and restore your entire Windows 95/98 partition, file by file, easily. Just, please, be patient until VFAT support is finished.

4. Compatibility

The following programs have been tested and seem to work fine, without any changes, in file access mode:

The following programs have been tested but they have to be forced to use Windows 95/98 long file name functions even under plain DOS:

The following programs have severe problems:

I haven't tested the programs above extensively, please, tell me if you find some problems. Try this program with other LFN-aware programs, too, and tell me about incompatibilities.

5. History

0.01 beta:

0.02 beta:

0.03 beta:

0.10 beta:

0.11 beta:

0.12 beta:

0.20 beta:

0.21 beta:

0.22 beta:

0.23 beta:

0.24 beta:

0.25 beta:

0.26 beta:

0.27 beta:

0.30 beta (2002-03-10):

0.31 beta (2002-09-08):

0.32 beta (2004-01-31):

6. Thanks to

Thanks go to the following people:

Fucks go to PC Magazine, the copyright owner of Rick Knoblaugh's LFNDir, for having published the source along with a ridiculous license that only allows others to make personal use of the source but distribute no derivative works at all! This program contains nothing at all from their lame intellectual property!

7. Error messages

8. Copyright and legal issues

The source of this program is public domain and provided here "as is" – I don't feel like commenting it more but if you have problems then feel free to ask me. If you derive your own program from the source or put a part of the source into your own program, please, give me a credit and send a copy to me.

9. The author

If you're interested in some similarly useful utilities you can contact me at sta.ANTI@SPAM.c64.org or visit my homepage at http://sta.c64.org.

Joe Forster/STA
31st January, 2004

(This page best viewed with any browser)