Hi Pietro.
On Thu, Jan 29, 2026 at 10:18:55AM -0500, Pietro Monteiro wrote: > On Wed, Jan 28, 2026, at 8:13 PM, Jose E. Marchesi wrote: > > Hi Pietro. > > Thanks for the patch. > > > >> _libga68_u32_to_u8 called free on the result buffer on error, but the > >> buffer is allocated by the GC, so calling free on it is incorrect. > > > > But if LIBGA68_WITH_GC is not defined then _libga68_malloc_leaf used the > > regular malloc, right? So the memory needs to be free or we will be > > leaking memory.. > > If libga68 is built without the gc we always leak memory anyway. That's not necessarily true. One can provide a `malloc' which implements a conservative garbage collection. Building Boehm GC is not an option for some baremetal platforms. And calling `free' maybe also implemented as a helper for the GC.
