Hi! config.c
- fix: sysVersion(): VERSION= now works properly by setting version for INT21/30, not for INT21/3306. - config now parsed in 5 passes: SWITCHES=/F/N and MENUCOLOR/MENUDEFAULT parsed before menu, INSTALL/SET after DEVICE (in MS-DOS6 all SET processed before INSTALL, but this now allows to redefined variables between INSTALL). - when tracing, Esc now turns off asks for following lines with "?" and assumes "Y" for all; F8 now behaves similar to Esc. main.c - PSPinit(): DOS_PSP.ps_environ and ps_parent now zero. - kernel(): "PATH=." now not placed into empty environment (because bug with copying empty env in task.c:ChildEnv() is fixed). - kernel(): now "/D" or "/Y" option inserted even if command line is too long (by trimming command line tail). task.c ! P_0(): old shell command line stored in SecPathName buffer and, thus, will be overwritten by DOS rename function with argument, longer than 50 bytes. - bugfix: ChildEnv(): empty environment now processed correctly. - bugfix: ChildEnv(): DosMemAlloc() was called with NULL for `asize', but asize not always checked inside DosMemAlloc() for NULL before dereference. - ChildEnv(): for environment now allocated memory not more, than required to store path after environment (was always 80 extra bytes). - bugfix: P_0() was copy argument of SHELL line into Shell buffer without checking length of source (note: max length of SHELL argument is a 74 bytes, because Shell=SecPathName+50 and sizeof SecPathName=128). - P_0(): now supported command line without space between command and options (starting from '/'). Also, today-tomorrow will be added: - config.c: CmdSet(): detect variables redefinition and removing. - config.c: make environment for each INSTALL=. And, two issues which I found (and plan to fix): ?! config.c: KernelAlloc(): returned wrong address when first_mcb==0; for example, with nBytes==15 && FP_OFF(lpTop)==1 returned area length==1. ?! task.c: new_psp(): under MS-DOS6 after INT21/26 ps_parent is not zero (but equal to current_psp.ps_parent); beside ps_isv* fields, MS-DOS6 also fixes the ps_filetab pointers. About allocating less memory in ChildEnv(): @@ -13,9 +13,9 @@ Segment Size Owner Type / sou -0595 464 LASTDRIVE= -0616 2.01k STACKS= 0616 40.5k <system> - 1039 112 --free-- + 1038 48 --free-- - 1040 78.0k COMMAND + 103B 78.0k COMMAND - 23C0 496k --free-- + 23BB 496k --free-- 9FEF 272 COMMAND environment -A000- ------------------------------------------------------- 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-kernel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/freedos-kernel
