gitweb: avoid double / in search form action link
The in-project search form needs to duplicate some of the logic of
the href() subroutine, because the parameters need to be encoded
in the form rather than in the URL. However it failed to correctly
append the project PATH_INFO in cases when there is a trailing slash
on gitweb's self-referential URL, and failed to correctly follow
PATH_INFO escaping rules.
This change makes the form action URL consistent with the URL
generated by href().
Signed-off-by: Tony Finch <dot@dotat.at>