home *** CD-ROM | disk | FTP | other *** search
- {$G+}type q=^char;const i=33;f=' found! ';n=' not';v='Env.';var s,j:word;b:q;
- function g(var v:q;var z:word):byte;assembler;var u:byte;e,p:word;
- asm mov ah,98;int i;mov es,bx;@SP:mov bx,es;mov dx,es:[22];mov es,dx;cmp dx,bx
- je @FP;cmp dx,0;jne @SP;mov al,1;jmp @X;@FP:mov p,dx;mov dx,es:[2ch];mov e,dx
- mov ah,88;mov al,2;int i;mov u,al;mov al,3;mov bx,1;int i;mov ah,82;int i
- mov dx,es;dec dx;mov es,dx;add bx,12;mov di,es:[bx];mov dx,es:[bx+2];mov es,dx
- @SM:inc dx;cmp dx,e;je @FM;cmp byte ptr es:[di],90;jne @CM;mov al,2;jmp @X
- @CM:mov cx,es:[di+3];mov dx,es;add dx,cx;inc dx;mov es,dx;mov di,0;jmp @SM
- @FM:mov dx,es:[di+3];shl dx,4;les di,z;mov es:[di],dx;mov dx,e;les di,v
- mov es:[di+2],dx;mov word ptr es:[di],0;mov al,0;@X:push ax;mov ah,88
- mov al,3;mov bl,u;int i;pop ax;end;begin case g(b,s)of
- 0:begin writeln(v+'&PSP'+f+v+'size:',s);j:=1;repeat if b^<>#0then begin
- write(b^);inc(b)end else begin writeln;inc(b);if b^=#0then j:=s;end;
- inc(j)until j>s end;1:writeln('PSP'+n+f);2:writeln(v+n+f)end;end.