max_charges_from_flag() tweaks