Some regular expression fixes