String theory frequently leads to four-dimensional models containing discrete symmetries which carry QCD anomalies and break spontaneously at an intermediate mass scale m. The domain walls associated with the spontaneous breaking of such anomalous discrete symmetries are potentially cosmologically disastrous. We find that this cosmological catastrophe is avoided if and only if M less than or similar to 10(7) GeV. We also show that this stringent bound on m can be circumvented if the anomalous discrete symmetry happens to be effectively embedded in an ''accidental'' approximate anomalous global U(1) symmetry. A specific model which exhibits this mechanism is presented. Although we restricted ourselves to string models, our discussion can be readily applied to other gauge models with spontaneously broken anomalous discrete symmetries too.