Fixed to not destroy event when the pid doesn't have a name.