2009-06-09 20:27:22 -04:00
|
|
|
/*
|
2009-06-11 19:47:56 -04:00
|
|
|
* Copyright (C) Internet Systems Consortium, Inc. ("ISC")
|
2009-06-09 20:27:22 -04:00
|
|
|
*
|
|
|
|
|
* SPDX-License-Identifier: MPL-2.0
|
2021-06-03 02:37:05 -04:00
|
|
|
*
|
2009-06-09 20:27:22 -04:00
|
|
|
* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
|
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
|
2018-02-23 03:53:12 -05:00
|
|
|
*
|
2009-06-09 20:27:22 -04:00
|
|
|
* See the COPYRIGHT file distributed with this work for additional
|
|
|
|
|
* information regarding copyright ownership.
|
|
|
|
|
*/
|
|
|
|
|
|
2021-10-05 10:49:47 -04:00
|
|
|
#pragma once
|
2009-06-09 20:27:22 -04:00
|
|
|
|
|
|
|
|
/*! \file */
|
|
|
|
|
|
2018-08-07 10:46:53 -04:00
|
|
|
#include <isc/attributes.h>
|
2009-06-09 20:27:22 -04:00
|
|
|
#include <isc/formatcheck.h>
|
|
|
|
|
|
|
|
|
|
#define NS_CONTROL_PORT 953
|
|
|
|
|
|
|
|
|
|
#undef DO
|
|
|
|
|
#define DO(name, function) \
|
|
|
|
|
do { \
|
|
|
|
|
result = function; \
|
|
|
|
|
if (result != ISC_R_SUCCESS) \
|
|
|
|
|
fatal("%s: %s", name, isc_result_totext(result)); \
|
|
|
|
|
else \
|
|
|
|
|
notify("%s", name); \
|
|
|
|
|
} while (0)
|
|
|
|
|
|
|
|
|
|
void
|
|
|
|
|
notify(const char *fmt, ...) ISC_FORMAT_PRINTF(1, 2);
|
|
|
|
|
|
2024-07-11 09:15:40 -04:00
|
|
|
ISC_NORETURN void
|
2018-08-07 10:46:53 -04:00
|
|
|
fatal(const char *format, ...) ISC_FORMAT_PRINTF(1, 2);
|