SDL2 memory leak in WSL2
Using very basic program of:
I get a pretty substantial memory leak:
Out of curiosity, does this happen with SDL3?
I'm not sure. I haven't tried SDL3. My understanding is that an official stable release hasn't come out yet for SDL3 so I was waiting on that before trying out SDL3.
SDL2 built under WSL2, is similar to building SDL2 on Linux. So aren't leaks from 3rd party libraries expected? Most/all leaks are from libdecor, gtk and dbus.
Using these suppressions with valgrind:
{ wsl2 Memcheck:Leak ... obj:/usr/lib/wsl/drivers/* ... }
{ valgrind_leaks Memcheck:Leak ... obj:/usr/libexec/valgrind/* ... }
Will suppress all of the memory leaks: