Fix try/catch problems, indicated by Eclipse