PEAR is discontinued

This is a static archive preserving historical releases and metadata. No new packages or updates will be published. For updates to existing packages, or to publish new packages, please use Composer and Packagist.

Home » File Formats » File_DNS » Bug #4528

GenerateZone uses fixed order in associative array

Details

Submitted2005-06-04 20:00 UTC
Frommetz at php dot net
Assignedcipri
StatusBogus
PackageFile_DNS
PHP Version4.3.11
Roadmaps(Not assigned)

Comments

[2005-06-04 20:00 UTC] metz at php dot net

Description:
------------
If the order of the associative array _records isn't 100% the zone will be corrupt.

try fixing:
--- DNS.php.orig 2005-06-04 21:52:03.000000000 +0200
+++ DNS.php 2005-06-04 21:52:34.000000000 +0200
@@ -667,7 +667,12 @@
case 'CNAME':
case 'PTR':
default:
- $zone[] = implode("\t", $record);
+ $zone[] = implode("\t", array(
+ $record['name'],
+ $record['ttl'],
+ $record['class'],
+ $record['type'],
+ $record['data']));
break;
}
}