fixing deadlocks due to free/malloc being called from signal handler

(this is not allowed, as it might lead to a heap deadlock
 if interrupting another malloc/free calll)

(now the reaction time to signals is a bit lower but no I was
 not able to reproduce any more deadlocks)
logging PID when killed