strip _all_ occurances of bad flags