What you are describing is known as "spalling.". It happens when the block gets wet, and then freezes. The water trapped inside the block expands and then breaks off small bits of the block, brick or stucco as it goes.I'm glad to hear that your basement has not flooded recently, however, the solution you took by just painting the walls most likely put off this inevitable deterioration. The best way to stop a basement from leaking is to address the real cause of the problem, which is ALWAYS roof and surface drainage. In short, you must have a well designed gutter system that is clean and free-flowing, with downspouts extended at least 4-6 feet from the foundation. In addition, the grade at the foundation perimeter must slope away from the home by at least 6 inches over the first 4 feet. These details are better explained in this article on how to stop a wet basement.As for the cosmetic damage you are now reporting, I would recommend that, AFTER you address the source of excessive moisture as explained above, you apply an epoxy patching compound the damage areas, and then repaint the foundation.