Stability of axial orbits in galactic potentials