From cfae86e5f17cdcdc5de259e0628d09d3d0c8e598 Mon Sep 17 00:00:00 2001 From: westley Date: Sat, 18 Mar 2017 11:38:43 -0600 Subject: [PATCH] tested soa packer. It works, but doesn't utilize compression pointers to full capabilities --- packer/type.soa.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/packer/type.soa.js b/packer/type.soa.js index c716c72..d79a9f5 100644 --- a/packer/type.soa.js +++ b/packer/type.soa.js @@ -27,7 +27,7 @@ exports.DNS_PACKER_TYPE_SOA = function (ab, dv, total, record) { } if(!record.ret){ throw new Error("no serial number for SOA record"); - } + } if(!record.ex){ throw new Error("no serial number for SOA record"); } @@ -35,7 +35,7 @@ exports.DNS_PACKER_TYPE_SOA = function (ab, dv, total, record) { throw new Error("no serial number for SOA record"); } - var soaLen = 20; // take into account sn, ref, ret, ex, and nx + var soaLen = 20; // take into account sn, ref, ret, ex, and nx // (32-bits each. 4Bytes * 5 = 20) var rdLenIndex = total; total += 2; // Save space for RDLENGTH @@ -72,7 +72,7 @@ exports.DNS_PACKER_TYPE_SOA = function (ab, dv, total, record) { dv.setUint32(total, parseInt(record.ref, 10), false); total+=4; dv.setUint32(total, parseInt(record.ret, 10), false); - total+=4; + total+=4; dv.setUint32(total, parseInt(record.ex, 10), false); total+=4; dv.setUint32(total, parseInt(record.nx, 10), false);