Fixed name parsing in --name-to-tags.