mirror of https://github.com/FDOS/kernel.git
Fix memory break in NUL device
This commit is contained in:
parent
e024f72a4c
commit
cab8092ad6
|
@ -212,6 +212,7 @@ uUnitNumber dw 0
|
||||||
; at any time. The request is stored into memory in the one and only
|
; at any time. The request is stored into memory in the one and only
|
||||||
; location available for that purpose.
|
; location available for that purpose.
|
||||||
;
|
;
|
||||||
|
global GenStrategy
|
||||||
GenStrategy:
|
GenStrategy:
|
||||||
mov word [cs:_ReqPktPtr],bx
|
mov word [cs:_ReqPktPtr],bx
|
||||||
mov word [cs:_ReqPktPtr+2],es
|
mov word [cs:_ReqPktPtr+2],es
|
||||||
|
|
|
@ -287,10 +287,9 @@ segment CONST
|
||||||
; NUL device strategy
|
; NUL device strategy
|
||||||
;
|
;
|
||||||
global _nul_strtgy
|
global _nul_strtgy
|
||||||
|
extern GenStrategy
|
||||||
_nul_strtgy:
|
_nul_strtgy:
|
||||||
mov word [cs:_ReqPktPtr],bx ;save rq headr
|
jmp far GenStrategy
|
||||||
mov word [cs:_ReqPktPtr+2],es
|
|
||||||
retf
|
|
||||||
|
|
||||||
;
|
;
|
||||||
; NUL device interrupt
|
; NUL device interrupt
|
||||||
|
@ -299,7 +298,9 @@ _nul_strtgy:
|
||||||
_nul_intr:
|
_nul_intr:
|
||||||
push es
|
push es
|
||||||
push bx
|
push bx
|
||||||
les bx,[cs:_ReqPktPtr] ;es:bx--> rqheadr
|
mov bx,LGROUP
|
||||||
|
mov es,bx
|
||||||
|
les bx,[es:_ReqPktPtr] ;es:bx--> rqheadr
|
||||||
cmp byte [es:bx+2],4 ;if read, set 0 read
|
cmp byte [es:bx+2],4 ;if read, set 0 read
|
||||||
jne no_nul_read
|
jne no_nul_read
|
||||||
mov word [es:bx+12h],0
|
mov word [es:bx+12h],0
|
||||||
|
|
Loading…
Reference in New Issue