Eric Auer schreef:


PS Bernd: Tell people to abort on the WHICHFAT critical error message. Then
"unformatted" is reported as 0, and FAT12/16/32 are all reported properly.
However, the kernel has to be fixed - there should be no interactive critical
error message when detecting an unformatted drive at all! Just store the
fact and return error 7, "no DOS drive". Do not try to init the BPB further.


are my FORMAT logs useful?

I can't help you with the "change kernel sources" and other technical info.
Currently, FAT12 users are out of luck: drive gets formatted because unformatted and FAT12 have the same errorlevel under freedos.
MSDOS uses errlvl 1 for unformatted, and errlvl 12 is OK then.
However, I don't know code to implement it:
@echo off
whichfat c:
If errorlevel 16 goto skipwipe // don't format
If "%errorlevel%'=="1" format c: // unformatted, msdos
If "%errorlevel%"=="12" format c: // unfortunately also wipes out FAT12 partitions with data on them


there no critical error stuff. COMMAND /F (auto-fail) was needed for some operations.
Perhaps a IF EXIST C:\*.* GOTO SKIPWIPE would help for FAT12.
the problem is that a drive may have no files in root, only directories.
In that case, no files are detected, drive is formatted, and bye bye data!


Bernd


-------------------------------------------------------
This SF.Net email sponsored by Black Hat Briefings & Training.
Attend Black Hat Briefings & Training, Las Vegas July 24-29 - digital self defense, top technical experts, no vendor pitches, unmatched networking opportunities. Visit www.blackhat.com
_______________________________________________
Freedos-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freedos-devel

Reply via email to