----- Original Message ----- From: "Dominic Hargreaves" dom@earth.li To: "OpenGuides software developers" openguides-dev@openguides.org Sent: 02 June 2004 14:22 Subject: Re: [OpenGuides-Dev] Bad handling of 8-bit characters;state change on GET request
On Wed, Jun 02, 2004 at 09:04:41AM -0400, IvorW wrote:
Anyway, you need CGI::Wiki::Plugin::Diff 0.06 and OpenGuides 0.31. Hopefully your diffing problem will go away.
I'm aware of the oddness with library search paths on the test wiki. However that's not where I'm running into the problem. Most of the diffs you try on http://www.ox.compsoc.net/oxfordguide/ seem to fail eg:
http://www.ox.compsoc.net/oxfordguide/?id=Sand_Box&version=6&diffversion=8
This is with OG 0.31 and C::W::P::D 0.06. I'll submit a bug once I've done a bit more digging.
Keep digging :).
However, the following patch should sort the error out. Let me know if this fixes it. If this is the case, I will release another CGI::Wiki::Plugin::Diff. I think this could be a case of similar to use strict - in this case use Params::Validate. I need to cater for _every_ possible data type that is passed.
--- Diff.pm Sat May 15 23:23:32 2004 +++ Diff_patched.pm Wed Jun 2 21:31:41 2004 @@ -90,7 +90,7 @@ sub line_number { my $self = shift;
- local ($_) = validate_pos(@_, {type => SCALAR, optional => 1} ); + local ($_) = validate_pos(@_, {type => SCALAR | UNDEF, optional => 1} ); return '' unless defined $_;
my $fmt = '"'. $self->{line_number_format} . '"';
Ivor.