Feature/boost memory leak fixes

Compilation of all the memory leak fixes (fix still in progress)