MPD regexp improvements

This is work in progress to resolve #552.