; available. It is based on the SYSLINUX boot loader for MS-DOS
; floppies.
;
-; Copyright (C) 1994-2004 H. Peter Anvin
+; Copyright (C) 1994-2005 H. Peter Anvin
;
; This program is free software; you can redistribute it and/or modify
; it under the terms of the GNU General Public License as published by
; If unsuccessful
; ZF set
;
-
+; Assumes CS == DS == ES, and trashes BX and CX.
;
; searchdir_iso is a special entry point for ISOLINUX only. In addition
; to the above, searchdir_iso passes a file flag mask in AL. This is useful
; for searching for directories.
;
-searchdir_iso.alloc_failure:
+alloc_failure:
xor ax,ax ; ZF <- 1
- jmp searchdir_iso.ret
+ ret
searchdir:
xor al,al
searchdir_iso:
- push bx
- push cx
mov [ISOFlags],al
TRACER 'S'
call allocate_file ; Temporary file structure for directory
- jnz .alloc_failure
+ jnz alloc_failure
push es
push ds
pop es ; ES = DS
.failure: xor eax,eax ; ZF = 1
mov [bx+file_sector],eax
- jmp .ret
+ pop es
+ ret
.success:
mov eax,[si+2] ; Location of extent
shr edx,16
and bx,bx ; ZF = 0
mov si,bx
-.ret:
pop es
- pop cx
- pop bx
ret
.resume: ; We get here if we were only doing part of a lookup