Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 1.3.0b4

Bug #14747 Net_IPv6::compress() Fails on Already-Compressed Addr
Submitted: 2008-10-05 20:53 UTC
From: guitarking117 Assigned: alexmerz
Status: Closed Package: Net_IPv6 (version 1.1.0RC4)
PHP Version: 5.2.6 OS: Suse Linux
Roadmaps: (Not assigned)    
Subscription  


Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know! Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
MUST BE VALID
Solve the problem : 11 - 1 = ?

 
 [2008-10-05 20:53 UTC] guitarking117 (Nicholas Williams)
Description: ------------ The function Net_IPv6::compress() is returning an empty string when passed a valid IP address that is already compressed. This issue was previously fixed in version 1.0.4, but has returned in 1.1.0RC4. Test script: --------------- // outputs nothing echo Net_IPv6::compress('2001:503:ba3e::2:30'); // outputs "2001:503:ba3e::2:30" echo Net_IPv6::compress('2001:503:ba3e:0:0:0:2:30'); // outputs nothing echo Net_IPv6::compress('ff01::101'); // outputs "ff01::101" echo Net_IPv6::compress('ff01:0:0:0:0:0:0:101'); Expected result: ---------------- If the address is already compressed, it should just return the address as it was passed to it. This would be in line with the behavior of the function Net_IPv6::umcompress(), which returns the address passed to it if it is already uncompressed. Actual result: -------------- It returns nothing if the address is already compressed.

Comments

 [2008-10-09 12:57 UTC] doconnor (Daniel O'Connor)
1) testBug14747(NetIPv6Test) Undefined variable: cip /usr/share/php/Net/IPv6.php:438 /usr/share/php/Net/IPv6.php:438 /home/clockwerx/pear/Net_IPv6/tests/NetIPv6Test.php:218
 [2008-11-03 17:51 UTC] alexmerz (Alexander Merz)
This bug has been fixed in CVS. If this was a documentation problem, the fix will appear on pear.php.net by the end of next Sunday (CET). If this was a problem with the pear.php.net website, the change should be live shortly. Otherwise, the fix will appear in the package's next release. Thank you for the report and for helping us make PEAR better.