Valgrind says that the illegal write is occurring at
If you look at that address as ASCII characters, it’s:
argorP t, or converting from little endian:
This looks like part of one of your menu items, “9. Abort Program”. Maybe the bug is that
menu_init() is writing past the end of the
I’d guess that stepping through your program in a debugger should find the problem quick enough.