RE: gitweb not friendly to firefox?
- From
- Li Yang-r58472 <leoli@freescale.com>
- Date
- Mar 2, 2007, 09:36 UTC
- Message-ID
- <989B956029373F45A0B8AF02970818902DA81B@zch01exm26.fsl.freescale.net>
- In-Reply-To
- <7v1wk8i1et.fsf@assigned-by-dhcp.cox.net>
Hi Jakub,
Problem sovled, using the following patch. I'm not an expert of perl, so I don't know if it is problem of the gitweb or problem with my perl environment. My environment is perl-5.8.0 and perl-CGI-2.81.
Signed-off-by: Li Yang<leoli@freecale.com> ---
diff --git a/gitweb/gitweb.perl b/gitweb/gitweb.perl index 653ca3c..8c9a291 100755 --- a/gitweb/gitweb.perl +++ b/gitweb/gitweb.perl @@ -591,7 +591,7 @@ sub esc_html ($;%) { my %opts = @_; $str = to_utf8($str); - $str = escapeHTML($str); + $str = $cgi->escapeHTML($str); if ($opts{'-nbsp'}) { $str =~ s/ / /g; } > -----Original Message----- > From: Junio C Hamano [mailto:junkio@cox.net] > Sent: Friday, March 02, 2007 2:51 PM > To: Li Yang-r58472 > Cc: rea-git@codelabs.ru; Raimund Bauer; git@vger.kernel.org; Jakub Narebski > Subject: Re: gitweb not friendly to firefox? > > "Li Yang-r58472" <LeoLi@freescale.com> writes: > > >> > Yes, you are right. But why gitweb didn't do that for me? I > > observed > >> > that some early version of gitweb doesn't have this problem. Is it > >> > possible that some new change caused this? > >> > >> It's very possible. > > > > Well, I had found out that the escapeHTML() is not functioning on my > > server. It leaves the "<", ">", "@" unchanged. Does anyone have a clue > > about it? I'm using Redhat 9.0 full installation. > > I am not sure offhand if escapeHTML implementation is wrong or > the call site is calling escapeHTML when it should be using some > other kinds of escape. > > The person who knows about this issue the best, if I have to > guess, would be Jakub Narebski. >