2 * Unix SMB/CIFS implementation.
3 * Internal DNS query structures
4 * Copyright (C) Volker Lendecke 2018
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; either version 3 of the License, or
9 * (at your option) any later version.
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
16 * You should have received a copy of the GNU General Public License
17 * along with this program; if not, see <http://www.gnu.org/licenses/>.
24 #include "libcli/dns/dns_lookup.h"
25 #include "lib/util/debug.h"
27 static int dns_lookuptest1(void)
29 struct dns_name_packet
*reply
= NULL
;
32 ret
= dns_lookup(NULL
, "www.samba.org", DNS_QCLASS_IN
, DNS_QTYPE_A
,
35 fprintf(stderr
, "dns_lookup failed: %s\n", strerror(ret
));
43 int main(int argc
, const char *argv
[]) {
46 setup_logging(argv
[0], DEBUG_DEFAULT_STDERR
);
47 debug_parse_levels("10");
49 ret
= dns_lookuptest1();