Fix path dispatch on Windows