# gitweb: pathinfo feature breaks commitdiff/raw links

3 messages from 2008-04-17 to 2008-04-17. Participants: martin f krafft, Wincent Colaiuta.
Thread: https://gitlist.dev/t/13151

## martin f krafft, 2008-04-17 09:23

Subject: gitweb: pathinfo feature breaks commitdiff/raw links
Message-ID: <20080417092339.GA17016@piper.oerlikon.madduck.net>
URL: https://gitlist.dev/e/20080417092339.GA17016%40piper.oerlikon.madduck.net

```
Hello,

as per suggestion in gitweb.cgi, I put the following into my
gitweb.conf:

  $feature{'pathinfo'}{'default'} = [1];

This mostly works, but James Vega recently found a corner case where
this is broken: the raw link of a commitdiff page, such as

  http://git.madduck.net/v/code/mailplate.git?a=commitdiff;h=f7d2365ee0ab439217083dd613daa4757a4e3d6e

suddenly becomes

  http://git.madduck.net/v/ARRAY(0xbc3b70)?a=commitdiff_plain;h=f7d2365ee0ab439217083dd613daa4757a4e3d6e
                           ^^^^^^^^^^^^^^^
when the feature is turned on. It works when it's off.

I discussed this a bit on IRC, with the following bottom line:

  < jengelh> if you see ARRAY... in the url, and [1] in the source
  the wise Perl person says "ah, of course"

Unfortunately, I am neither wise nor a Perl person, so I resort to
just pointing this out to you and can offer to test any patches on
this live server.

Cheers,

-- 
martin | http://madduck.net/ | http://two.sentenc.es/
 
"it is only the modern that ever becomes old-fashioned." 
                                                        -- oscar wilde
 
spamtraps: madduck.bogus@madduck.net

```

## Wincent Colaiuta, 2008-04-17 09:57

Subject: Re: gitweb: pathinfo feature breaks commitdiff/raw links
Message-ID: <869CFE40-B245-4744-A9D5-0F3FA623633F@wincent.com>
URL: https://gitlist.dev/e/869CFE40-B245-4744-A9D5-0F3FA623633F%40wincent.com
In-Reply-To: <20080417092339.GA17016@piper.oerlikon.madduck.net>

```
El 17/4/2008, a las 11:23, martin f krafft escribió:
> Hello,
>
> as per suggestion in gitweb.cgi, I put the following into my
> gitweb.conf:
>
>  $feature{'pathinfo'}{'default'} = [1];
>
> This mostly works, but James Vega recently found a corner case where
> this is broken: the raw link of a commitdiff page, such as
>
>  http://git.madduck.net/v/code/mailplate.git?a=commitdiff;h=f7d2365ee0ab439217083dd613daa4757a4e3d6e
>
> suddenly becomes
>
>  http://git.madduck.net/v/ARRAY(0xbc3b70)?a=commitdiff_plain;h=f7d2365ee0ab439217083dd613daa4757a4e3d6e
>                           ^^^^^^^^^^^^^^^
> when the feature is turned on. It works when it's off.
>
> I discussed this a bit on IRC, with the following bottom line:
>
>  < jengelh> if you see ARRAY... in the url, and [1] in the source
>  the wise Perl person says "ah, of course"
>
> Unfortunately, I am neither wise nor a Perl person, so I resort to
> just pointing this out to you and can offer to test any patches on
> this live server.

Are you running an older version of gitweb? One which predates 7863c61?

Cheers,
Wincent

```

## martin f krafft, 2008-04-17 10:11

Subject: Re: gitweb: pathinfo feature breaks commitdiff/raw links
Message-ID: <20080417101118.GA26063@piper.oerlikon.madduck.net>
URL: https://gitlist.dev/e/20080417101118.GA26063%40piper.oerlikon.madduck.net
In-Reply-To: <869CFE40-B245-4744-A9D5-0F3FA623633F@wincent.com>

```
also sprach Wincent Colaiuta <win@wincent.com> [2008.04.17.1157 +0200]:
> Are you running an older version of gitweb? One which predates 7863c61?

Yes, sorry for not including that information.

piper:~/code/git> git describe 7863c61
v1.5.4.4-10-g7863c61

I run the 1.5.4.2-1 Debian backport.

I assume from your answer that 1.5.4.4 fixes this issue and will
gladly wait.

-- 
martin | http://madduck.net/ | http://two.sentenc.es/
 
"they redundantly repeated themselves over and over,
 incessantly without end and ad infinitum"
                                                             -- ibid
 
spamtraps: madduck.bogus@madduck.net

```
