normalizes any pathname to one leading slash and no trailing slash