git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: Potential bug in gitweb 1.7.2

From
Jakub Narebski <jnareb@gmail.com>
Date
Jul 26, 2010, 14:23 UTC
Message-ID
<201007261623.05850.jnareb@gmail.com>
In-Reply-To
<4C4D932A.1010101@gmail.com>
On Mon, 26 Jul 2010, Julio Lajara wrote:
Show 8 quoted lines
> Hi, Ive managed to narrow down the issue to a line in the gitolite's 
> contrib/gitweb/gitweb.conf that I appended to the default 
> /etc/gitweb.conf . It was working with 1.7.0.4 but 1.7.2 doesnt like 
> this line:
> 
> $ENV{GL_USER} = $cgi->remote_user || "gitweb";
> 
> I corrected it by just setting it equal to gitweb and all is well now.

I think the following commit is the reason that this stopped working 869d588 (gitweb: Move evaluate_gitweb_config out of run_request, 2010-07-05)

>From its commit message:
    gitweb: Move evaluate_gitweb_config out of run_request
    
    Move evaluate_gitweb_config() and evaluate_git_version() out of
    run_request() to run(), making them not run one for each request.
    This changes how git behaves in FastCGI case.
    
    This change makes it impossible to have config which changes with
    request, but I don't think anyone relied on such (hidden action)
    behavior.

I guess I was wrong about that. I wonder if it would be possible to re-enable this feature (which I think is needed to be able to use $cgi->remote_user) but without having all pay the [slight] performance penalty of including (and I think parsing) config file once per each request.

-- 
Jakub Narebski
Poland
Previous: Julio LajaraNext: Jonathan Nieder
Message 8 of 15 in “Potential bug in gitweb 1.7.2”
  1. Julio LajaraJul 26, 2010
  2. Jonathan NiederJul 26, 2010
  3. Anders KaseorgJul 26, 2010
  4. Julio LajaraJul 26, 2010
  5. Jakub NarebskiJul 26, 2010
  6. Ævar Arnfjörð BjarmasonJul 26, 2010
  7. Julio LajaraJul 26, 2010
  8. Jakub NarebskiJul 26, 2010
  9. gitweb: allow configurations that change with each requestJonathan Nieder, Jul 31, 2010
  10. Jakub NarebskiAug 2, 2010
  11. Jonathan NiederAug 2, 2010
  12. Jakub NarebskiAug 2, 2010
  13. Jonathan NiederJul 26, 2010
  14. Anders KaseorgJul 26, 2010
  15. Jonathan NiederJul 27, 2010

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.