java maze stack bug modiyf