emikulic / darkhttpd

When you need a web server in a hurry.
https://unix4lyfe.org/darkhttpd/
ISC License
1.05k stars 87 forks source link

500 for not found directory listing #51

Closed hhartzer closed 8 months ago

hhartzer commented 8 months ago

I noticed this weird behavior if you do GET /404/ (note the trailing /).

It responds with a 500 instead of a 404.

<html><head><title>500 Internal Server Error</title></head><body>
<h1>Internal Server Error</h1>
Couldn't list directory: No such file or directory
<hr>
</body></html>
g-rden commented 8 months ago

This should be fixed with #45. Does the version you tested include this change?

hhartzer commented 8 months ago

Good catch! Exactly right.

Thank you!

hhartzer commented 8 months ago

When I was working on this, I was adding a test case to devel/test.py. Then I noticed that the tests weren't passing fully, but it said tests were successful...

I opened #52 for that.