Make the regex work in Python 2.6