Skip to content

Commit

Permalink
Merge pull request #172 from unlimitedbacon/master
Browse files Browse the repository at this point in the history
Make sure createDirectory sets Z on success
  • Loading branch information
ddevault committed Oct 27, 2015
2 parents 63eef26 + cdd4876 commit 06aeba5
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions src/00/filesystem.asm
Original file line number Diff line number Diff line change
Expand Up @@ -612,6 +612,7 @@ _: ; Move DE to end of file entry
ei
_: pop af
pop ix
cp a
ret
.exitError:
pop hl
Expand Down Expand Up @@ -699,12 +700,14 @@ _: push de
ld de, 0
.createEntry:
call createDirectoryEntry
jr nz, .error2
inc sp \ inc sp ; pop hl
pop de
pop af
jp po, _
ei
_: pop af
cp a
ret
.error:
pop hl
Expand All @@ -718,6 +721,16 @@ _: pop af
or 1
ld a, errFileNotFound
ret
.error2:
inc sp \ inc sp ; pop hl
pop de
pop af
jp po, _
ei
_: pop af
or 1
ld a, errFilesystemFull
ret

; findNode
; Finds a node in the FAT.
Expand Down

0 comments on commit 06aeba5

Please sign in to comment.