Fix some right-click GUI crashes