import re


def remove_control_characters(string):
    """Removes control characters and other funny business that will
    interfere with XML parser. Destructive."""
    return re.sub(r'[\x00-\x1F]+', '', string)