Back to home page

DOS ain't dead

Forum index page

Log in | Register

Back to the forum
Board view  Mix view

save & restore environment (Developers)

posted by jadoxa Homepage E-mail, Queensland, Australia, 08.03.2026, 01:39

> COMMAND.COM is from EDR DOS 20250427

This is failing because it is not getting the key, it is getting the prefix of the key.

C:\>type test.bat
set d11=d11
set d12=d12
set d13=d13
set D1=d1
set D1=D1
set

C:\>command.com /c set | tail -1
COMSPEC=J:\COMMAND.COM

C:\>command.com /c test.bat | tail -4
COMSPEC=J:\COMMAND.COM
D13=D13
D1=d1
D1=D1


(COMSPEC is J: because I'm actually running this in MSDOS Player in Win10.)

When it gets the key it doesn't check there's an equals after it, hence the key will match any other variable that starts with it.

 

Complete thread:

Back to the forum
Board view  Mix view
23231 Postings in 2189 Threads, 405 registered users (0 online)
DOS ain't dead | Admin contact
RSS Feed
powered by my little forum