PEAR is archived and read-only

This mirror preserves historical PEAR package releases and metadata so existing references remain available.

Home » Networking » Net_DNS » Bug #2141

Preference of 0 Not Allowed

Details

Submitted2004-08-16 21:34 UTC
Fromjwilborn at uslec dot com
Assignedekilfoil
StatusClosed
PackageNet_DNS
PHP Version4.3.8
OSFedora Linux
Roadmaps(Not assigned)

Comments

[2004-08-16 21:34 UTC] jwilborn at uslec dot com

Description:
------------
Lines 71 and 81 of MX.php should read: 'if (is_numeric($this->preference)) {'. This is so preferences of 0 can be set. Similar changes would be required for SRV.php.

Reproduce code:
---------------
Update or add any MX or SRV record with a preference of 0.

Expected result:
----------------
Packet built with proper rdata populated.

Actual result:
--------------
Packet is built with rdata of 'no data'.

[2004-11-25 00:28 UTC] eric at ypass dot net

Thank you for taking the time to write to us, but this is not
a bug.

Preference should never be used for an MX record. It's not portable across DNS server software and it will cause problems. This will not be fixed.

[2004-11-25 00:29 UTC] eric at ypass dot net

Err.. that should say "Preference 0 should never be used..."

[2004-12-02 06:10 UTC] eric at ypass dot net

Thank you for taking the time to write to us, but this is not
a bug.

Understood. Your point makes sense. Preference 0 is valid and therefore shouldn't be considered invalid. I'll agree with you technically... but I will highly discourage the pratice, though this is hardly the forum. :)

Thanks for the contribution.

-eric

[2005-04-08 12:25 UTC] cox at idecnet dot com

This bug has been fixed in CVS.

In case this was a documentation problem, the fix will show up at the
end of next Sunday (CET) on pear.php.net.

In case this was a pear.php.net website problem, the change will show
up on the website in short time.

Thank you for the report, and for helping us make PEAR better.