home *** CD-ROM | disk | FTP | other *** search
-
- ; This file patches two changes into version 1.0 of CMD. The first change
- ; makes it reset the shell bit in the message buffer command status flag so
- ; that the external or internal error handler will be invoked for bad commands.
- ; Before, the error was treated as a shell error, which resulted in the entire
- ; shell stack being cleared. The second change eliminates the extra space
- ; after the prompt character '>' in the command prompt. This extra space was
- ; confusing in cases where one wanted deliberately to enter a command with a
- ; leading space to force invocation of the ZCPR33 extended command processor.
- ;
- ; This file should be assembled to a HEX file and overlaid on CMD.COM using the
- ; MLOAD command line: MLOAD CMDNEW=CMD.COM,CMDPATCH1.
- ;
- ; Jay Sage, April 17, 1987
-
- patch equ 480h ; End of existing program code
- resume equ 10bh ; Where existing code actually started
- fix equ 26ah ; Address of extra ' ' in string
-
- ; Vector to patch
-
- org 100h
-
- jp patch
-
- ; Fix command prompt string
-
- org fix
-
- db 0 ; Replace ' ' by null
-
- ; New code stuck on end
-
- org patch
-
- ld hl,(109h) ; Get ENV address
- ld de,22h ; Offset to Z3MSG
- add hl,de
- inc hl ; Offset to command status flag
- inc hl
- inc hl
- res 0,(hl) ; Reset the shell bit
- jp resume ; Resume original code
-
- end
-