#11 A couple of problems in ioman.c in EFSL 0.2.7

closed
nobody
None
5
2006-09-12
2006-08-26
Mike Anton
No

There are a couple of problems in ioman.c. The first
one I found while trying to call ioman_writeSector()
directly. It turns out that the call to if_writeBuf()
always returns 0, or at least it does when using the
SD card interface. Alas, the test done is <= 0, so it
always fails with an error. But, the library still
worked ok, as ioman_flushSector() which calls
ioman_writeSector() had its conditional test flipped
as well. The call to ioman_writeSector() in
ioman_directSectorWrite() however, would have failed,
as it was done correctly (but I think it is not called
by any of the library code).

I fixed ioman_writeSector() by testing for != 0 the
same as ioman_readSector(). Similarily, I fixed the
conditional in ioman_flushSector(). Define PATCH to
enable these patches.

The updated file is attached.

Hopefully this helps some of you,

Mike

Discussion

  • Mike Anton
    Mike Anton
    2006-08-26

    Updated ioman.c

     
    Attachments
  • Lennart
    Lennart
    2006-09-12

    Logged In: YES
    user_id=1223110

    Hi Mike,

    The test(s) were indeed wrong. Fixed in 0.2.9!

    Thanks for your help!

     
  • Lennart
    Lennart
    2006-09-12

    • status: open --> closed