Commit Briefs

Thomas Adam

gotsh: avoid a temporary buffer for the socket path

ok stsp


Thomas Adam

add a test for ssh connections without a repo path argument

would have caught the fixed failure in disposing early-closed connections in gotd. ok jamsek, stsp


Thomas Adam

gotsh: validate with parse_command before connecting

Export parse_command (now got_serve_parse_command) from lib/serve.c and use it to validate the command line in gotsh instead of just checking that the -c argument starts with 'git-receive-pack' or 'git-upload-pack'. Invalid usage now always fails before opening the socket, while before it wasn't always the case. This also means that invalid usage doesn't count towards the limits. ok jamsek, stsp


Thomas Adam

gotd: disconnect on client EOF too

Otherwise gotd keeps the (client-closed) sockets around and may prevent new connections from being established since they still count for the limits. ok jamsek, stsp


Thomas Adam

fmt; fold long line


Thomas Adam

gotwebd: avoid full history traversal in briefs/commits

This purposefully breaks the 'previous' button in the commits and briefs page. It's hard to find the parent of a commit since they can only be iterated forward. The way the previous button was generated was to walk the history from the HEAD down to the specified commit. This is costly but more importantly leads to issue when dealing with paths that were deleted from the repository. Discussed with stsp and tracey, ok jamsek.


Thomas Adam

gotwebd: don't got_ref_list per-commit in got_get_repo_commits

It's wasteful since `refs' is already populated before the loop, and released after. It also leaks the content of `refs' the first time the loop is entered. ok jamsek


Thomas Adam

gotwebd: turn gotweb_get_time_str into gotweb_render_age

ok jamsek


Thomas Adam

gotwebd: refactor gotweb_render_content_type/_file

Rework them so that they allow to set the Status header (the HTTP status code; only way since we're behind FastCGI) and optionally a Location. Since they're now unused outside of gotweb.c, mark them as static. They also used to always return NULL so the error is pointless; return the -1 on failure though. While here, rename to gotweb_reply and gotweb_reply_file. ok jamsek



Thomas Adam

return GOT_ERR_EOF from pkt.c if a read attempt indicates EOF

ok jamsek



Thomas Adam

make gotd session process accept just one flush packet at a time

ok jamsek


Thomas Adam

sort ENVIRONMENT entries in got.1 and tog.1

ok jamsek


Thomas Adam

portable: set next version


Thomas Adam

portable: release 0.81 (tags/0.81)


Thomas Adam

portable: template: use as a subproject

Move template into its own subproject as it's only needed at compile-time and shouldn't be installed. This needs compiling with the host compiler which is configurable via HOSTCC and HOSTCLFAG environment variables. This diff largely from op@ but additional tweaking from myself.


Thomas Adam

gotwebd.8: sort -d after -D

patch by Josiah Frentsos, thanks!


Thomas Adam

gotd.8, gotwebd.8: new sentence, new line

diff from Josiah Frentsos, thanks!



Thomas Adam

fix typo: overlapping comparison always evaluates false

ok stsp@


Thomas Adam

bump version number


Thomas Adam

changes for 0.81