ring-clojure / ring

Clojure HTTP server abstraction
MIT License
3.73k stars 518 forks source link

function ring.util.response/file-response doesn't work with opt. :root like "C:\\" in Windows #457

Open dima0905 opened 2 years ago

dima0905 commented 2 years ago

I try to resolve and foundout that .getCanonicalPath has strange behavior: useful-stuff.multitool> (.getCanonicalPath (File. "c:")) "C:\Users\Intel" useful-stuff.multitool> (.getCanonicalPath (File. "c:/")) "C:\" useful-stuff.multitool> (.getCanonicalPath (File. "c:\")) "C:\"