1 /* -*- Mode: C; tab-width: 4 -*-
3 * Copyright (c) 2002-2018 Apple Inc. All rights reserved.
5 * Licensed under the Apache License, Version 2.0 (the "License");
6 * you may not use this file except in compliance with the License.
7 * You may obtain a copy of the License at
9 * http://www.apache.org/licenses/LICENSE-2.0
11 * Unless required by applicable law or agreed to in writing, software
12 * distributed under the License is distributed on an "AS IS" BASIS,
13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 * See the License for the specific language governing permissions and
15 * limitations under the License.
18 #include "../mDNSMacOSX/DNSServiceDiscovery.h"
19 #include "DNSServiceDiscoveryDefines.h"
23 #include <servers/bootstrap.h>
24 #include <mach/mach.h>
25 #include <mach/mach_error.h>
28 #include <netinet/in.h>
30 extern boolean_t
DNSServiceDiscoveryReply_server(
31 mach_msg_header_t
*InHeadP
,
32 mach_msg_header_t
*OutHeadP
);
35 kern_return_t DNSServiceBrowserCreate_rpc
45 kern_return_t DNSServiceResolverResolve_rpc
56 struct a_requests
*next
;
57 mach_port_t client_port
;
59 DNSServiceBrowserReply browserCallback
;
60 DNSServiceDomainEnumerationReply enumCallback
;
61 DNSServiceRegistrationReply regCallback
;
62 DNSServiceResolverReply resolveCallback
;
67 typedef struct _dns_service_discovery_t
{
69 } dns_service_discovery_t
;
72 dns_service_discovery_ref
DNSServiceBrowserCreate (const char *regtype
, const char *domain
, DNSServiceBrowserReply callBack
,void *context
)
75 (void) regtype
; // Unused
76 (void) domain
; // Unused
77 (void) callBack
; // Unused
78 (void) context
; // Unused
80 printf("DNSServiceBrowserCreate deprecated since 10.3 \n");
85 dns_service_discovery_ref
DNSServiceResolverResolve(const char *name
, const char *regtype
, const char *domain
, DNSServiceResolverReply callBack
, void *context
)
87 (void) name
; // Unused
88 (void) regtype
; // Unused
89 (void) domain
; // Unused
90 (void) callBack
; // Unused
91 (void) context
; // Unused
93 printf("DNSServiceResolverResolve deprecated since 10.3 \n");
98 void DNSServiceDiscovery_handleReply(void *replyMsg
)
100 (void) replyMsg
; // Unused
101 printf("DNSServiceDiscovery_handleReply deprecated since 10.3 \n");
104 mach_port_t
DNSServiceDiscoveryMachPort(dns_service_discovery_ref dnsServiceDiscovery
)
106 printf("DNSServiceDiscoveryMachPort deprecated since 10.3 \n");
107 return dnsServiceDiscovery
->port
;
110 void DNSServiceDiscoveryDeallocate(dns_service_discovery_ref dnsServiceDiscovery
)
112 (void) dnsServiceDiscovery
; // Unused
113 printf("DNSServiceDiscoveryDeallocate deprecated since 10.3 \n");