develooper Front page | perl.perl5.porters | Postings from March 2014

[perl #121512] .pmc not loaded if @INC has a trailing slash

Thread Previous | Thread Next
Tony Cook via RT
March 31, 2014 23:28
[perl #121512] .pmc not loaded if @INC has a trailing slash
Message ID:
On Mon Mar 31 05:32:55 2014, alh wrote:
> > RT-116192 - If a directory in @INC already has a trailing '/', don't
> > add another.
> My apologies! Patch attached.
> The original code always assumed a '/' would be appended, so it set
> the length of the resulting SV to be +1.
> With my earlier patch, this wasn't the case if the SV already ended in
> a '/', so later checks on the SV that were based off the length of the
> SV would be wrong.
> New tests included.

I think this patch or something like it should be applied to blead and backported.

The only issue I have with the patch itself is it could be simpler, instead of adding extra variable, the if could simply ++dirlen when it bumps tmp.

Nothing else within the scope depends on dirlen being the length of the original @INC entry.


via perlbug:  queue: perl5 status: open

Thread Previous | Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About