Hi, I was wondering if this would work correctly:
What can be done about this?
Thanks!
You must use free() function from same libc instance that was used to allocate it.
If you use xcb library then there's no reason to avoid libc - as it requires you to use its libc instance to free() pointers. You need to link to same libc dynamically - which can be glibc or musl depending on distro.
Symbol resolving on Linux works a bit differently from Windows. Loading multiple libc instances in same process is really not supported and most likely won't work. You need to use libraries that are compiled with same libc implementation & loads same instance into your process. Otherwise you'll have strange errors and have really bad time.