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

Bug #16445 setArgs problem
Submitted: 2009-07-17 10:40 UTC
From: leon01 Assigned: neufeind
Status: Closed Package: Net_Traceroute (version 0.21.1)
PHP Version: 5.2.5 OS: Linux
Roadmaps: (Not assigned)    
Subscription  


 [2009-07-17 10:40 UTC] leon01 (Leonid Freeman)
Description: ------------ If used as described in the example provided with the package I think the example isn't correct for the Linux you can write it this way $traceroute->setArgs(array()); Test script: --------------- example1.php from the package $traceroute->setArgs(array('numeric'=>NULL)); $data=$traceroute->traceroute($host); Actual result: -------------- the result command for Linux will be traceroute -n '' 2>&1 yahoo.com the system response will be : Name or service not known Cannot handle "host" cmdline arg `' on position 1 (argc 2) The problem is single quotes.

Comments

 [2009-07-18 13:53 UTC] doconnor (Daniel O'Connor)
-Type: Bug +Type: Documentation Problem
 [2010-10-20 12:48 UTC] neufeind (Stefan Neufeind)
-Status: Open +Status: Closed -Type: Documentation Problem +Type: Bug -Assigned To: +Assigned To: neufeind
This bug has been fixed in SVN. 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. Problem was actually that an empty argument (numeric doesn't have a parameter) resulted in empty single-quotes being appended. But an option without a value is perfectly fine. Added check for empty value, so documentation itself is correct and it was actually a bug when creating the commandline.