All Things Microsoft > Microsoft Software
Strange string in command.com
Kintaro:
Dos was never based on Unix, in fact, its so different to Unix that the notion of it is Insane.
The /dev/ bit is probably what tells the system that it is a device, but opening a file with the typical API called "Con", "Aux", etc is basically opening a device. Dos has no /dev/ directory on the filename, no such thing as device nodes, just a crude API for input/serial/printer devices.
It is NOT unix. Also, CP/M had the same thing.
Aloone_Jonez:
I know that but they did borrow some UNIX concepts like redirection and pipes which is possibly where the devices /CON /NUL came from.
Jenda:
--- Quote ---Actually, it's a crudely constructed CP/M clone that was made for Apple IIs and old 8080 machines. Quick and Dirty Operating System. I think it was done by a guy at a software firm to see if he could. MS bought this hack and sold it as MS-DOS.
--- End quote ---
They just removed the "quick" part. :)
Kintaro:
--- Quote from: Aloone_Jonez ---I know that but they did borrow some UNIX concepts like redirection and pipes which is possibly where the devices /CON /NUL came from.
--- End quote ---
I don't think pipes were in CP/M, just QDOS and MSDOS. However I am not sure, I know they were in MP/M. In fact when you read on MP/M you wonder why the hell it didn't blow MSDOS out of the water.
anphanax:
Hey, you've got XP or 2K laying around, check this out (this stuff doesn't exist in WinDOS 9x):
con\prn\nul\aux\com#\lpt# are just the tip of a much bigger iceberg :P.
For instance, although stupid, you can make your floppy drive light up by typing this in cmd.exe:
"more < \\.\GLOBALROOT\DEVICE\Floppy0"
If I recall correctly, those are all in some sort of kernel namespace (\..\?), and a lot of that junk isn't accessible in user-mode windows (in other words, I think some stuff, like the contents of the "Drivers" path, is only accessible in kernel-mode). Also, I believe there's a specialized undocumented API for working with kernel objects on NT. "NtQueryObject" from NTDLL.DLL comes to mind, for one.
Navigation
[0] Message Index
[*] Previous page
Go to full version