I created a folder named "DEBUG" on a floppy disk:
mkdir debug
Then i tried to give the same floppy disk the volume name "DEBUG" but this failed.
If i try to do a
label A:
and enter the string "DEBUG" without quotes as name, the volume label of the floppy becomes empty.
If i use any other name, it works.
This seems to be a bug and it is reproducible and it depends on if a directory of the same name does exist.
If i have the directories:
bin
devel
work
on the floppy disk, then i can't give the volume label of that floppy disk the name
"BIN", "DEVEL" or "WORK".
**
It get's even worse.**
If i create a file, and use the same name for the volume label, then the file vanishes and the volume label gets that name.
Example:
edit relevant
This opens EDIT.EXE, then write some important stuff in this file and save and exit EDIT.EXE
dir A:
...
Directory of A:\
RELEVANT 50 21-07-2022 4:27P
Now give the floppy disk the same label:
label A:
Enter "RELEVANT" as volume name.
If done, enter dir A:
DIR A:
...
Directory of A:\
The file is gone and with it its content.
It's not possible to get the file back by renaming the volume label to something else or by using undelete.
I tested this on FreeDOS 1.3 and on MS-DOS 6.2
In MS-DOS 6.2 i don't have this problem.
In MS-DOS i can give the volume label the same name as of a file or directory and the file and directory stays. Thus this is a serious bug in FreeDOS 1.3.
Added a bug report at the project development repository for the it's maintianer.
Github LABEL Issue #17 - File and directory collision bug
Hi,
I just tested this behaviour, it is close to what I already reported about label. I just do not find my report, so I add it here.
a) It does not write the label to TWO but only to one position.
b) When a folder (e.g. TEST01) already exists, it does NOT delete the folder but it does not
create a label "TEST01" with the label command. The name is changed at the second position
to "(a with an o on top)EST01"
c) when a filename without an ending (otherwise it does not work) already exists (e.g. file01) is used for a label (file01) the file is deleted. Reason: "(a with an o on top)EST01" stays and the new label name jumps to the filename position.
Enclosed some screenshots made with an hexeditor to show you what happens. If possible please forward it to Github LABEL Issue #17 or add a link to here.
Thanks.
There is an explanation of this behaviour, see:
https://gitlab.com/FreeDOS/base/label/-/issues/1
last comment (Andrew Bird).
Just to inform you.
Marking as closed because this issue is already being tracked. See issue 1 in the FreeDOS GitLab tracker