We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 981d016 commit 4e43287Copy full SHA for 4e43287
1 file changed
drdos/bdevio.asm
@@ -834,6 +834,19 @@ ifdef FATPLUS
834
mov ax,byteoff+6
835
adc ax,0
836
mov fsize+6,ax
837
+else
838
+ jnc fdw_e03 ; file size + fdrwcnt <4GB?
839
+ mov ax,fsize ; otherwise restrict fdrwcnt
840
+ sbb fdrwcnt,ax
841
+ jnz fdw_e02 ; can write at least a single byte?
842
+ mov ax,ED_ACCESS ; if not return access denied
843
+ jmp fdos_error
844
+fdw_e02:
845
+ xor ax,ax
846
+ dec ax
847
+ mov fsize,ax
848
+ mov fsize+2,ax
849
+fdw_e03:
850
endif
851
; div clsize ; AX whole blocks required
852
; push dx
0 commit comments