Category : C Source Code
Archive   : JAZLIB.ZIP
Filename : JZCHRSTR.ASM
Output of file : JZCHRSTR.ASM contained in archive : JAZLIB.ZIP
ÚÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ¿
³jzchrstr ³
³Concatenate a character onto the end of a string adding the null character ³
³ ³
³Parms ³
³ wstr = string to concatenate to ³
³ wch = char to concatenate ³
³ ³
³Synopsis: ³
³ ³
³ strcpy(wstr,"hello ther"); ³
³ wch = 'e' ³
³ jzchrstr(wstr,wch); ³
ÀÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÙ
*
;=============================================================================
; Data
;=============================================================================
DGROUP group _DATA
_DATA segment word public 'DATA'
assume ds:DGROUP
; Your Data goes here . . .
_DATA ends
;=============================================================================
; Code
;=============================================================================
assume cs:_text
_text segment public byte 'code'
PUBLIC _jzchrstr
_jzchrstr proc near
push bp ; save base of stack
mov bp,sp ; establish stack frame
push di ; save MS-C's Register vars
mov di,[bp].4 ; get address of dest string
mov bx,[bp].6 ; get character value to concatenate
xor bh,bh ; set high byte
xor ax,ax ; search for a zero byte
mov cx,0FFFFh ; allow 64k max str length
repnz scasb
dec di
mov byte ptr [di],bl ; get char into string
inc di
mov byte ptr [di],bh ; get zero into last byte
pop di ; Restore MS-C's Register vars
mov sp,bp ; restore stack pointer
pop bp ; and base of stack
ret ; return to caller
_jzchrstr endp
_text ends
end
Very nice! Thank you for this wonderful archive. I wonder why I found it only now. Long live the BBS file archives!
This is so awesome! 😀 I’d be cool if you could download an entire archive of this at once, though.
But one thing that puzzles me is the “mtswslnkmcjklsdlsbdmMICROSOFT” string. There is an article about it here. It is definitely worth a read: http://www.os2museum.com/wp/mtswslnk/