Small fixes in mercurial handler