~kernevil/ubuntu/trusty/bind9/sdlz-hmac-keys

« back to all changes in this revision

Viewing changes to bin/dig/nslookup.c

  • Committer: Package Import Robot
  • Author(s): LaMont Jones, Matthew Grant, LaMont Jones
  • Date: 2012-10-29 08:37:49 UTC
  • mfrom: (1.9.2)
  • Revision ID: package-import@ubuntu.com-20121029083749-r9inpzl0yuj9xdlu
Tags: 1:9.8.4.dfsg-1
[Matthew Grant]

* Turn off dlopen as it was causing test compile failures.
* Add missing library .postrm files for debhelper

[LaMont Jones]

* New upstream version
* soname fixup
* Ack NMUs

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/*
2
 
 * Copyright (C) 2004-2011  Internet Systems Consortium, Inc. ("ISC")
 
2
 * Copyright (C) 2004-2012  Internet Systems Consortium, Inc. ("ISC")
3
3
 * Copyright (C) 2000-2003  Internet Software Consortium.
4
4
 *
5
5
 * Permission to use, copy, modify, and/or distribute this software for any
15
15
 * PERFORMANCE OF THIS SOFTWARE.
16
16
 */
17
17
 
18
 
/* $Id: nslookup.c,v 1.127.38.2 2011-02-28 01:19:58 tbox Exp $ */
 
18
/* $Id: nslookup.c,v 1.127.38.2 2011/02/28 01:19:58 tbox Exp $ */
19
19
 
20
20
#include <config.h>
21
21
 
57
57
static char defclass[MXRD] = "IN";
58
58
static char deftype[MXRD] = "A";
59
59
static isc_event_t *global_event = NULL;
 
60
static int query_error = 1, print_error = 0;
60
61
 
61
62
static char domainopt[DNS_NAME_MAXTEXT];
62
63
 
406
407
printmessage(dig_query_t *query, dns_message_t *msg, isc_boolean_t headers) {
407
408
        char servtext[ISC_SOCKADDR_FORMATSIZE];
408
409
 
 
410
        /* I've we've gotten this far, we've reached a server. */
 
411
        query_error = 0;
 
412
 
409
413
        debug("printmessage()");
410
414
 
411
415
        isc_sockaddr_format(&query->sockaddr, servtext, sizeof(servtext));
433
437
                       (msg->rcode != dns_rcode_nxdomain) ? nametext :
434
438
                       query->lookup->textname, rcode_totext(msg->rcode));
435
439
                debug("returning with rcode == 0");
 
440
 
 
441
                /* the lookup failed */
 
442
                print_error |= 1;
436
443
                return (ISC_R_SUCCESS);
437
444
        }
438
445
 
887
894
        destroy_libs();
888
895
        isc_app_finish();
889
896
 
890
 
        return (0);
 
897
        return (query_error | print_error);
891
898
}