lclevy / ADFlib

A free, portable and open implementation of the Amiga filesystem
GNU General Public License v2.0
90 stars 30 forks source link

Bug fixes (mainly from address sanitizer) #26

Closed t-w closed 1 year ago

t-w commented 1 year ago

I have added address sanitizer to debug compilation (with CMake). It let to catch a couple of memory leaks (mainly in tests, so no big deal), and one buffer overflow in library code (a bit bigger deal...).

Also, a minor correction in adfChangeDir() (check if the entries' sector from hashtable is valid before trying to read its block).

I have also enabled more compiler checks - it gives a lot of warnings, some of them will be worth checking (it not, they can be disabled or partially suppressed).

t-w commented 1 year ago

(Sorry, I have submitted this before I saw today's notification... Maybe you could just merge this, next time I do it directly.)

lclevy commented 1 year ago

Thanks