problems with file search routine
Posted: Sat Apr 03, 2004 12:00 am
whats wrong with this code?
mov si,offset filename
mov di,7E00h
mov cx,root_entries
search_root:
push si
push cx
mov cx,11
rep cmpsb
je found_file
pop cx
pop si
add di,21
loop search_root
jmp kernel_load_error
it never finds the file...
i know the root directory was successfully placed at offset 7E00h
because ive tried dumping the memory to screen and all the filenames showed up
mov si,offset filename
mov di,7E00h
mov cx,root_entries
search_root:
push si
push cx
mov cx,11
rep cmpsb
je found_file
pop cx
pop si
add di,21
loop search_root
jmp kernel_load_error
it never finds the file...
i know the root directory was successfully placed at offset 7E00h
because ive tried dumping the memory to screen and all the filenames showed up