Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

When I compare a dir in DOSBox 0.74 against a dir from Windows 7 command prompt, the 8.3 filenames differ.

Long format (both drives and directories):


DOSBox 0.74 (dir):

2012-0~2 7Z
2012-0~4 7Z
2012-1~2 ZIP

Windows 7 (dir /x):


so for instance if I'm passing in a path to DOSBox, sometimes this happens and whatever I'm trying to automate will fail. Why the difference, and can I change any settings to help DOSBox generate the correct shortnames?

share|improve this question
up vote 1 down vote accepted

This has been reported to the DOSBox authors around 4.5 years back, and unfortunately they prefer to call this bug a "feature":

we are aware of that. Think the dosbox ones are always the windows ones in a different order. It wouldn't be easier to use the windows api function as then dosbox has different behaviour on different oses.

Don't think there's any way around it TBH, unless you make the changes yourself and compile your own copy, or are lucky enough to find one already made by someone else.

share|improve this answer
Thanks. I didn't know Windows saved shortname as metadata. At least the DOSBox alphabetizing is something that can be scripted around. – wes Nov 28 '12 at 3:36
Yeah, you can even turn off the 8.3 short filenames completely so that only LFNs are stored. Just type fsutil behavior set disable8dot3 1 at an elevated command prompt. – Karan Nov 28 '12 at 15:38

There is already a solution for this by now. Try the latest enhanced DOSBox SVN build with Long File Name (LFN) support (and also the right mouse button copy/paste feature). It should support long filenames as well as using the same 8.3 filenames as the Windows system itself uses.

Latest Windows binary + required DLLs, zipped:

Related forum discussions & sources:

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.