Skip Menu |

This queue is for tickets about the Apache-CVS CPAN distribution.

Report information
The Basics
Id: 293
Status: open
Worked: 3 min
Priority: 0/
Queue: Apache-CVS

People
Owner: Nobody in particular
Requestors: briac [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Normal
Broken in: 0.02
Fixed in: (no value)



The Apache::CVS::CVS.pm file emits a couple of warnings, so here's a patch that should hopefully fix this. -- briac
--- /usr/lib/perl5/site_perl/5.6.1/Apache/CVS/Revision.pm Mon Feb 18 23:44:10 2002 +++ /home/briac/perl/CVS.fix.pl Mon Feb 18 23:44:41 2002 @@ -173,11 +173,11 @@ $time{days} = ($diff - $remainder) / $seconds_in_day; $diff = $remainder; - $remainder = $diff % $seconds_in_hour; + my $remainder = $diff % $seconds_in_hour; $time{hours} = ($diff - $remainder) / $seconds_in_hour; $diff = $remainder; - $remainder = $diff % $seconds_in_minute; + my $remainder = $diff % $seconds_in_minute; $time{minutes} = ($diff - $remainder) / $seconds_in_minute; $time{seconds} = $remainder;
Subject: Installed version is different from code from tarball.
Thank you for looking at Apache::CVS. I went to apply your patch, but from what I can see, the code already looks like how you want it to look. I downloaded the Apache CVS tarball just to make sure all the $remainders are declared with my. Any idea why your installation would be different or am I reading the direction of the diff incorrectly? please advise. [BRIAC - Mon Feb 18 17:49:53 2002]: Show quoted text
> The Apache::CVS::CVS.pm file emits a couple of warnings, so here's a > patch that should hopefully fix this.
Date: Tue, 19 Feb 2002 09:09:40 +0100
From: Briac Pilpré <briac [...] pilpre.com>
To: via RT <bug-Apache-CVS [...] rt.cpan.org>
Subject: Re: [cpan #293] Installed version is different from code from tarball.
via RT (bug-Apache-CVS@rt.cpan.org) wrote: Show quoted text
> I went to apply your patch, but from what I can see, the code already > looks like how you want it to look. I downloaded the Apache CVS > tarball just to make sure all the $remainders are declared with my. > > Any idea why your installation would be different or am I reading the > direction of the diff > incorrectly?
Oops, I now realize that the patch I gave you inverted the original/patched files. So here's the right version (patched from a fresh CPAN download, just to be sure :) Note that the $remainder variable should only be declared with 'my' once in the same scope. Actually, the reason I looked at the code of your module was that Apache ended up taking 98% of CPU time when displaying a revision of a file. Any clue on the reason of this behaviour? Thanks, Briac -- briac << dynamic .sig on strike, we apologize for the inconvenience >>

Message body is not shown because sender requested not to inline it.

Date: Tue, 19 Feb 2002 06:27:55 -0800
From: barbee [...] veribox.net
To: Briac PilprX via RT <bug-Apache-CVS [...] rt.cpan.org>
Subject: Re: [cpan #293] Installed version is different from code from tarball.
Patch committed. It'll be in the next release. Viewing a revision involves checkout out the revision of that file, reading it into memory, replacing all the HTML special characters with &lt; and &gt;, and finally printing it. Are you trying to view a revision of a large file? I tried viewing a revision but didn't notice any marked increase in CPU usage. The only thing else I can think of off the top of my head is spawning the process to do the checkout pegs the processor. Please let me know. Thanks for the patch. barbee. On Tue, Feb 19, 2002 at 03:09:51AM -0500, Briac PilprX via RT wrote: Show quoted text
> > > via RT (bug-Apache-CVS@rt.cpan.org) wrote:
> > I went to apply your patch, but from what I can see, the code already > > looks like how you want it to look. I downloaded the Apache CVS > > tarball just to make sure all the $remainders are declared with my. > > > > Any idea why your installation would be different or am I reading the > > direction of the diff > > incorrectly?
> > Oops, I now realize that the patch I gave you inverted the > original/patched files. So here's the right version (patched from a > fresh CPAN download, just to be sure :) > > Note that the $remainder variable should only be declared with 'my' > once in the same scope. > > Actually, the reason I looked at the code of your module was that > Apache ended up taking 98% of CPU time when displaying a revision of a > file. Any clue on the reason of this behaviour? > > Thanks, > Briac > > -- > briac > << dynamic .sig on strike, we apologize for the inconvenience >> >