When two different life forms live in the same place and one is clearly fitter than the other, the less fit tends to become extinct. Crocodilians are older than the dinosaurs - in fact, they are older than modern lizards and snakes. If the upright gait of crocodilians was fundamentally better in all respects than the sprawling gait of lizards, lizards would have been replaced long ago by tiny crocodiles.
The answer, as is the case for many seemingly "primitive" species outcompeting more modern ones, is energy cost. Holding the body upright requires the leg muscles to be constantly in use, which means the animal uses more energy and therefore requires more food and oxygen. Most reptiles have "low energy" lifestyles - they spend a lot of their time lying around and don't need to eat or breathe as much as comparatively-sized mammals.
The "breathing" part is most relevant here. While lizards are restricted by Carrier's constraint, it really isn't such a big issue for them, since the same posture that makes it hard for them to breathe also means they don't need to breathe as much. While it does mean that they can't run long distances to chase down prey, they don't really need to.
Crocodilians occupy a midway point in the high-energy and low-energy lifestyles, a unique niche which is strongly linked to their semi-aquatic lifestyle. They can put on bursts of speed that most lizards can't handle, and avoid the disadvantage of an upright (or partially upright) posture by using water to support their bodies. The crocodilian form is specialized for a water-dweller, and it is unlikely that it would be retained by a fully terrestrial animal.
In the past, there were periods where crocodilians actually did diverge into many different niches, and the forms they took closely resembled other species that occupied their niches at other points in history - terrestrial crocs either went fully upright, or fully sprawling. Over time, the high-energy terrestrial lifestyle was dominated by dinosaurs and later mammals, while the low-energy terrestrial lifestyle was dominated by lizards.
Unless your world is significantly different than Earth, there will probably be low-energy niches available. As a result, even if all species at some point in time have given up the sprawling gait, sooner or later upright species will return to the sprawling gait to fill those low-energy niches. It isn't fundamentally inferior to an upright one, just specialized for a different niche.