Hello, Paolo. > and recreating the function from scratch leaks even more. Idem, > someone can confirm this? Could you please provide some example? I can try to valgrind then. -- With best regards, Anton Korobeynikov. Faculty of Mathematics & Mechanics, Saint Petersburg State University.