]> git.saurik.com Git - apple/mdnsresponder.git/commitdiff
mDNSResponder-214.3.2.tar.gz mac-os-x-1064 v214.3.2
authorApple <opensource@apple.com>
Mon, 12 Apr 2010 22:50:56 +0000 (22:50 +0000)
committerApple <opensource@apple.com>
Mon, 12 Apr 2010 22:50:56 +0000 (22:50 +0000)
Makefile
mDNSMacOSX/mDNSMacOSX.c
mDNSShared/dns_sd.h

index 93d4c3285009637768eb89c3c8a3850e58f2ca0d..04462ee4fe59c1fade9fb697b43cd69f64b2c311 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -16,7 +16,7 @@
 
 include /Developer/Makefiles/pb_makefiles/platform.make
 
-MVERS = "mDNSResponder-214.3"
+MVERS = "mDNSResponder-214.3.2"
 
 DDNSWRITECONFIG = "$(DSTROOT)/Library/Application Support/Bonjour/ddnswriteconfig"
 
index 0c6684f0d711e1d6aad5899caad64e87ffc58a9b..f621c696e2629fbb32aa04af3186b13f1105c670 100644 (file)
@@ -5456,7 +5456,7 @@ mDNSlocal mDNSu16 GetPortArray(mDNS *const m, int trans, mDNSIPPort *portarray)
        (((RR)->resrec.InterfaceID && (RR)->resrec.InterfaceID != mDNSInterface_LocalOnly) || \
        (!(RR)->resrec.InterfaceID && ((RR)->ForceMCast || IsLocalDomain((RR)->resrec.name))))
 
-mDNSlocal mDNSu32 CountProxyRecords(mDNS *const m, uint32_t *numbytes)
+mDNSlocal mDNSu32 CountProxyRecords(mDNS *const m, uint32_t *const numbytes)
        {
        *numbytes = 0;
        int count = 0;
@@ -5466,16 +5466,17 @@ mDNSlocal mDNSu32 CountProxyRecords(mDNS *const m, uint32_t *numbytes)
                        if (TfrRecordToNIC(rr))
                                {
                                *numbytes += DomainNameLength(rr->resrec.name) + 10 + rr->resrec.rdestimate;
-                               LogSPS("CountProxyRecords: %3d %5d %5d %s", count, DomainNameLength(rr->resrec.name) + 10 + rr->resrec.rdestimate, *numbytes, ARDisplayString(m,rr));
+                               LogSPS("CountProxyRecords: %3d size %5d total %5d %s",
+                                       count, DomainNameLength(rr->resrec.name) + 10 + rr->resrec.rdestimate, *numbytes, ARDisplayString(m,rr));
                                count++;
                                }
        return(count);
        }
 
-mDNSlocal mDNSu16 GetProxyRecords(mDNS *const m, DNSMessage *msg, uint16_t numbytes, FatPtr *records)
+mDNSlocal void GetProxyRecords(mDNS *const m, DNSMessage *const msg, uint32_t *const numbytes, FatPtr *const records)
        {
        mDNSu8 *p = msg->data;
-       const mDNSu8 *const limit = p + numbytes;
+       const mDNSu8 *const limit = p + *numbytes;
        InitializeDNSMessage(&msg->h, zeroID, zeroID);
 
        int count = 0;
@@ -5490,10 +5491,11 @@ mDNSlocal mDNSu16 GetProxyRecords(mDNS *const m, DNSMessage *msg, uint16_t numby
                                        rr->resrec.rrclass |= kDNSClass_UniqueRRSet;    // Temporarily set the 'unique' bit so PutResourceRecord will set it
                                p = PutResourceRecordTTLWithLimit(msg, p, &msg->h.mDNS_numUpdates, &rr->resrec, rr->resrec.rroriginalttl, limit);
                                rr->resrec.rrclass &= ~kDNSClass_UniqueRRSet;           // Make sure to clear 'unique' bit back to normal state
-                               LogSPS("GetProxyRecords: %3d %p %p %s", count, records[count].ptr, p, ARDisplayString(m,rr));
+                               LogSPS("GetProxyRecords: %3d start %p end %p size %5d total %5d %s",
+                                       count, records[count].ptr, p, p - (mDNSu8 *)records[count].ptr, p - msg->data, ARDisplayString(m,rr));
                                count++;
                                }
-       return(count);
+       *numbytes = p - msg->data;
        }
 
 // If compiling with old headers and libraries (pre 10.5) that don't include IOConnectCallStructMethod
@@ -5502,7 +5504,7 @@ mDNSlocal mDNSu16 GetProxyRecords(mDNS *const m, DNSMessage *msg, uint16_t numby
 static kern_return_t
 IOConnectCallStructMethod(
        mach_port_t      connection,            // In
-       uint32_t         selector,              // In
+       uint32_t         selector,                      // In
        const void      *inputStruct,           // In
        size_t           inputStructCnt,        // In
        void            *outputStruct,          // Out
@@ -5575,7 +5577,7 @@ mDNSexport mStatus ActivateLocalProxy(mDNS *const m, char *ifname)
                                                cmd.tcpPorts .ptr, cmd.numTCPPorts);
                                        else
                                                {
-                                               GetProxyRecords(m, msg, cmd.rrBufferSize, cmd.rrRecords.ptr);
+                                               GetProxyRecords(m, msg, &cmd.rrBufferSize, cmd.rrRecords.ptr);
                                                GetPortArray(m, mDNSTransport_UDP, cmd.udpPorts.ptr);
                                                GetPortArray(m, mDNSTransport_TCP, cmd.tcpPorts.ptr);
                                                char outputData[2];
index 39d84a651ffb6a4dc179f2ef32865bbb189600e9..1cffd7c2e844e5296806a6c168d3d508f9a2ac8b 100644 (file)
@@ -77,7 +77,7 @@
  */
 
 #ifndef _DNS_SD_H
-#define _DNS_SD_H 2140300
+#define _DNS_SD_H 2140302
 
 #ifdef  __cplusplus
     extern "C" {