Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!utgpu!water!watnot!watmath!clyde!rutgers!sri-spam!ames!oliveb!intelca!mipos3!pinkas From: pinkas@mipos3.UUCP Newsgroups: comp.sys.ibm.pc Subject: Re: Patch Command.Com Message-ID: <448@mipos3.UUCP> Date: Thu, 12-Feb-87 16:50:56 EST Article-I.D.: mipos3.448 Posted: Thu Feb 12 16:50:56 1987 Date-Received: Sat, 14-Feb-87 00:27:25 EST References: <380@neoucom.UUCP> <75800019@uiucdcsp> Reply-To: pinkas@mipos3.UUCP (Israel Pinkas) Organization: Intel, Santa Clara, CA Lines: 44 In article <75800019@uiucdcsp> version B 2.10.3 4.3bsd-beta 6/6/85; site mipos3.UUCP mipos3!intelca!amd!amdcad!sun!decwrl!decvax!mcnc!gatech!cuae2!ihnp4!inuxc!pur-ee!uiucdcs!uiucdcsp!vanzandt vanzandt@uiucdcsp.cs.uiuc.edu writes: > > > As I understand the /p parameter with the shell command it is >to be used in conjuction with the /e:nn (set environment size) to signify >that this is a "permanent" addition to the environment setting. Maybe they >mean that each child shell should inherit the same environment when the >/p parameter is specified???... No, No, No. Quoting from the DOS manual: (PC-DOS 2.0, page 10-10) "When a secondary command processor has been loaded, you can cause it to return to the previous level of command processor by issuing the special command EXIT. If you used the /P parameter, it will not retrun to the previous level (refer to Appendix F for additional information." (Appendix F has no relevance on the current discussion. -igp) As far as DOS 2.x is concerned, the /E parameter doesn't exist. It actuall does, but they didn't document it. The /E parameter determines the size of the environment. In 3.2 and above, it is measured in bytes. In 3.1 and below (including 2.x) it is measured in paragraphs (16 bytes). As I mentioned in a previous posting, DOS 3.2 appears to allocate the memory in paragraphs, so giving it a size that is not a multiple of 16 wastes a few bytes of memory. Another case of MS fixing something that wasn't broken or requested. The second thing to remember is that by default, the environment size that DOS allocates a new version of COMMAND.COM (a subshell if you like) is the greater of either the default size (160 bytes) or the current size. In any case, you will not be able to add to the environment if it is full. A workaround is to set the COMSPEC variable to include /E specification. In DOS 3.2, I understand that you may specify the value of COMSPEC in the SHELL= line in config.sys. Not owning DOS 3.x, I cannot comment on the validity of this method. (Someone posted the syntax a few days ago.) -Israel -- ---------------------------------------------------------------------- UUCP: {amdcad,decwrl,hplabs,oliveb,pur-ee,qantel}!intelca!mipos3!pinkas ARPA: pinkas%mipos3.intel.com@relay.cs.net CSNET: pinkas%mipos3.intel.com