tevent: make sure we don't set errno within the signal handler function.