libmemdisc: flush every second upon free()

If the game uses SIGALRM, then there is an issue with that flush
method. But somewhen we have to flush the output buffer. It is
most important when ending the game process. In that moment there
are a lot of free()s. So flush every second upon free().

Reported-by: Anonymous Linux Gamer