Return-Path: Delivered-To: apmail-perl-modperl-archive@www.apache.org Received: (qmail 46170 invoked from network); 7 May 2009 17:28:31 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 7 May 2009 17:28:31 -0000 Received: (qmail 77144 invoked by uid 500); 7 May 2009 17:28:29 -0000 Delivered-To: apmail-perl-modperl-archive@perl.apache.org Received: (qmail 77123 invoked by uid 500); 7 May 2009 17:28:29 -0000 Mailing-List: contact modperl-help@perl.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: List-Id: Delivered-To: mailing list modperl@perl.apache.org Received: (qmail 77115 invoked by uid 99); 7 May 2009 17:28:28 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 07 May 2009 17:28:28 +0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests=HTTP_ESCAPED_HOST,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: local policy) Received: from [206.63.25.115] (HELO mail.livesite.net) (206.63.25.115) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 07 May 2009 17:28:19 +0000 Received: from localhost (localhost [127.0.0.1]) by mail.livesite.net (Postfix) with ESMTP id DCC8EE3973 for ; Thu, 7 May 2009 10:27:57 -0700 (PDT) X-Virus-Scanned: amavisd-new at livesite.net Received: from mail.livesite.net ([127.0.0.1]) by localhost (mail.livesite.net [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id uk9ii6SsRMRN for ; Thu, 7 May 2009 10:27:53 -0700 (PDT) Received: from devbox.lsnllc (c-98-216-98-199.hsd1.ma.comcast.net [98.216.98.199]) (using TLSv1 with cipher DHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) by mail.livesite.net (Postfix) with ESMTPSA id 06B33E3972 for ; Thu, 7 May 2009 10:27:52 -0700 (PDT) Date: Thu, 7 May 2009 13:27:49 -0400 From: Ryan Gies To: modperl@perl.apache.org Subject: Apache2::URI::unescape_url Message-ID: <20090507132749.0b67a5c4@devbox.lsnllc> Organization: Livesite Netwoks, LLC X-Mailer: Claws Mail 3.7.1 (GTK+ 2.12.8; i686-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org I'm rather surprised at what I'm seeing, but it appears this method (Apache2::URI::unescape_url) is not correctly updating the length scalar variable. Any thoughts? -Ryan Output from the below response handler snippet: Before: 'http%3A%2F%2Fexample.com' After : 'http://example.com^@e.com' Alternate output (when url encoding the result): Before: 'http%3A%2F%2Fexample.com' After : 'http://example.com%00e.com/ --8<-------------------------------------------- package Apache2::Test::T1; use strict; use Apache2::URI; sub handler { my $r = shift; $r->content_type('text/plain'); my $url = 'http%3A%2F%2Fexample.com'; $r->print(sprintf("Before: '%s'\n", $url)); Apache2::URI::unescape_url($url); $r->print(sprintf("After : '%s'\n", $url)); Apache2::Const::OK; } 1; -------------------------------------------->8--