On the Euler equation for minimal geodesics on Riemannian manifolds having discontinuous metrics