gem-graph-client/include
Jean Sirmai fcc2dd1c6e
include/fsm.h, src/fsm/*: reworked memory management of the logging system
This commits reworks the way that memory is allocated for the logging system.

We basically use a double-linked list, with the oldest and the latest elements
stored in a static variable. Most recent log entries are added at the latest
position in this structure.

A new function to clear and free a log unit has been implemented, and can be used
at many points. We take care that each log unit is freed at closing time.

Also, fsm docs have been a bit clarified.

Tested with valgrind:

==6161== LEAK SUMMARY:
==6161==    definitely lost: 5,008 bytes in 54 blocks
==6161==    indirectly lost: 16,119 bytes in 672 blocks

We can consider that as a basis for future work, as these leaks are due to external
causes (e.g. libraries).

Signed-off-by: Jean Sirmai <jean@a-lec.org>
Signed-off-by: Adrien Bourmault <neox@a-lec.org>
2024-11-20 17:59:09 +01:00
..
base.h src/*, simple Gtk application 2024-11-20 17:38:36 +01:00
fsm.h include/fsm.h, src/fsm/*: reworked memory management of the logging system 2024-11-20 17:59:09 +01:00
widget.h src/widget/*, src/main.c: catching window::close-request signal, and a few renames 2024-11-20 17:59:09 +01:00