fix merge error
fix slash coalescence; normalize path in now-public dirname function