in reply to atomic operations

How about killing the process in question with a SIGSTOP first, so no progress is maded toward termination, then rechecking the name, if ok send SIGKILL and SIGCONT if not ok too.