This potentially deletes the source/switch choice, which then triggers a "use-after-free". Resolves #759