Commit Briefs

df2d3cd254 Omar Polo

gotwebd: provide gotweb_render_page() entrypoint for all pages

simplify gotweb_process_request more, handling all the pages inside the big switch. There's only one entrypoint for rendering the templates gotweb_render_page() that takes the page' content as argument. The only real difference is that gotweb_render_index() now skips directory entries which fails to handle. ok tracey@


3a1c1a1b20 Omar Polo

gotwebd.conf: use `listen on socket' syntax for UNIX sockets too

and drop unix_socket and unix_socket_path in server context. ok stsp@


8556b86bf7 Omar Polo

fmt


d5996b9efc Landry Breuil

add respect_exportok flag, defaulting to off

allows to hide repositories if they have the magic git-daemon-export-ok file ok op@ tracey@ stsp@


47b307cd82 Omar Polo

gotwebd.conf: add syntax for defining macros and document them

macros are already supported by parse.y but can only be defined with the -D flag. This adds the ``usual'' syntax for macros: varname = string. While here, fix the markup of the -D flag in the SYNOPSIS and sync the global `grammar' yacc rule with other parse.y grammars in base: - add the /* empty */ comment - increment file->errors on errors ok stsp@, "sure, go for it" tracey@


4cdd299d8c Omar Polo

gotwebd: fix crash handling -D

Avoid crashing by corrupting the pointer instead of writing to it and fix how sym is generated: it shouldn't include the '=' sign. ok / improvement tb@


b1328b3e37 Omar Polo

gotwebd: garbage collect %token FCGI_SOCKET

ok stsp@


6c8aa58fb8 Stefan Sperling

remove fcgi_socket keyword from gotwebd.conf; "listen on" now implies it

ok op@


67d8de2a7e Stefan Sperling

allow multiple "listen on" statements per server in gotwebd.conf

ok tracey


17132eaa7c Stefan Sperling

change gotwebd.conf fcgi socket syntax to "listen on 'foo' port 'bar'"

ok op@


859aa9f483 Stefan Sperling

fix previous: store port number in host byte order, convert for struct sockaddr

With the previous patch the listen port was correct, but the debug log output was still displaying the swapped port number. Now both listen behaviour and debug log output agree.


d72940a3a1 Stefan Sperling

fix gotwebd default fcgi listen port byte-order (port 10275 -> port 9000)

ok tracey


2fb25d87ff Stefan Sperling

gotwebd: listen on localhost only by default

ok tracey


73ffdfc038 Stefan Sperling

gotwebd: don't listen on FCGI sockets when FCGI is not enabled

ok tracey


2ad48e9a6b Stefan Sperling

gotwebd: do not allocate server/socket list heads separately

ok millert@


e087e1f6e7 Stefan Sperling

gotwebd: do not allocate address list heads separately, this is unnecessary

ok millert@


438d0cc30b Omar Polo

fix snprintf error handling

follow the "proper secure idiom" described in the CAVEATS section of printf(3). reminded by tb@ and millert@


d8473d93ab Stefan Sperling

convert gotwebd.conf "bind interface IP/iface" to "listen on IP/iface"

ok kn, tracey


a0037b737b Stefan Sperling

make gotwebd start up without a config file

ok tracey


86b4b772a2 Stefan Sperling

move use of sin_len out of gotwebd's parse.y

ok tracey


86fbc0d4ba Thomas Adam

gotwebd: remove tls.h

TLS isn't currently being used within gotwebd, so this include can be removed. Notice by naddy, and OK stsp@


a596b95796 Tracey Emery

import gotwebd

thread fcgi response to client for rendering in browser as data is returned fix potential problem with a stuck loop if the client is hammering the server with random clicks and stop/restarts render our index! WOOHOO! small var refactoring. fcgi.c to handle all clean-up, various error clean-up remove output used to trace down got bug temporarily stop overloading a socket, but a better solution needs to be found return on fcgi_gen_response, so we can track if a client is writable or not this stops page creation when the client is unavailable remove old comments enable profile building, although, i don't think this works thoroughly in a priv/proc daemon catch more errors correctly count repos remove temp logger we don't need to start our responder thread so early. move it to fcgi.c and start when we start processing html kill the unneeded thread, stop queueing responses, and just write to clients immediately clean up some memory leaks and dead stores rework querystring so an error can be displayed instead of showing the index on querystring error get framework in place for the rest of the content add server struct to response struct bo last commit get back a usable gotweb. not sure what i was thinking yesterday properly move our structs around this time remember index page for sitelink, fix leak unused var is annoying, so stop it for now. don't forget to change this! style briefs nearly completed. finish briefs output add briefs to summary cleanup some html properly retrieve next and previous commit ids for list navigation follow naddy's stailq macro change we will never have a previous link on the summary page goto correct label, so we get a previous link on the last page of briefs don't wrap short line simplify got_get_repo_commits code start rendering a diff start rendering a diff this was by accident finish diff output functions cleanup prepare for fd request that was a stupid idea, just flush the priv_fd bo that too. that won't work eith with append in mkstemp that isn't going to work actually zero out the priv_fd missed seek to beginning of file was overwriting first line of diff fsync our fd as well add link to repo path by sitelink and add back verbose fcgi debugging that was removed add modest write heuristics to fcgi_send_response fix dead assignments and XXX comment where a leak is happening that I can't find right now there was no leak. stsp is brilliant and knew it was the cache growing prevent double-free, render prettier err output if we can remove unused variables correctly fix double-free fix gotwebd to build with main's changes after rebase fix double-free don't error on index if pack files missing and fixup some error handling render commits finish up tag briefs and start the tag page finish up tag page unbreak TAGS and SUMMARY actions grab the correct tag from the queue unbreak TAGS and SUMMARY actions again update some error handling clean up unneeded code and start tree output render tree render branches remove tags from summary if there aren't any fix tree div structure and start blob render render blob render blame fix tree href in briefs clean up some css add headref to querystrings load correct commit for tree and diff fixup some error output update some copyright dates add full SNI support rm debug line found by Lucas6023, notified via IRC. thanks!! fix tree fix crash when querystring is manipulated to not have a commit id in certain instances. also break a stuck while loop on client error. fix for new got_object_id_by_path arguments rebase and fix prep for multiple fds per socket, instead of just one fix overlooked shift/reduce conflicts backout priv_fds as a list. after discussion with stsp, an array and length are the better direction prepare array of fds to pass into got functions make a new set of pack fds, which will be passed to got_repo_open work with new pack_fds in got_repo_open give output when no tags exist escape html in blame output change files listed in tree view to show blob, file commits, and blame, instead of blob, blob, blame. idea from mp4 on irc. this is way more handy. stop populating the queue from the headref and figure out previous commit id while iterating. this should reduce some overhead. actually purge our sockets instead of not using the function start work with new blob rm volatile use new diff change func names no more temp files increase blame number line width set content-type to text/plain so firefox won't download files rm test infra for now account for -Wwrite-strings fix for sigs and algorithm choice clean up some leaks and other mistakes