Commits


use a helper to handle no-body replies


rename goodbye -> close_conn


trim initial forward slashes this parse gemini://example.com///foo into an IRI whose path is "foo". I'm not 100% this is standard-compliant but: 1. it seems a logical consequence of the URI/IRI cleaning algo (where we drop sequential slashes) 2. practically speaking serving file a sequence of forward slashes doesn't really make sense, even in the case of CGI scripts


add ends_with


fix redirects make sure redirect starts with /. This also requires a tweak in check_path, in the case we go open_file -> send_dir -> open_file -> check-path and the path starts with a slash.


ensure we're in the correct state


sync changes


add missing getprogname test + eventually include err.h


const-ify parameter to strtonum


use recallocarray it also does an overflow check on multiplication, other than being more readable.


use strtonum


more OpenBSD goodies


rename mimes to mime ; pass config esplicitly to mime* functions


typo


fix prototypes