2009-06-10 00:27:22 +00:00
|
|
|
/*
|
2009-06-11 23:47:56 +00:00
|
|
|
* Copyright (C) Internet Systems Consortium, Inc. ("ISC")
|
2009-06-10 00:27:22 +00:00
|
|
|
*
|
|
|
|
* SPDX-License-Identifier: MPL-2.0
|
2021-06-03 08:37:05 +02:00
|
|
|
*
|
2009-06-10 00:27:22 +00: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 09:53:12 +01:00
|
|
|
*
|
2009-06-10 00:27:22 +00:00
|
|
|
* See the COPYRIGHT file distributed with this work for additional
|
|
|
|
* information regarding copyright ownership.
|
|
|
|
*/
|
|
|
|
|
2021-10-05 16:49:47 +02:00
|
|
|
#pragma once
|
2009-06-10 00:27:22 +00:00
|
|
|
|
|
|
|
/*! \file */
|
|
|
|
|
2018-08-07 16:46:53 +02:00
|
|
|
#include <isc/attributes.h>
|
2009-06-10 00:27:22 +00: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 16:15:40 +03:00
|
|
|
ISC_NORETURN void
|
2018-08-07 16:46:53 +02:00
|
|
|
fatal(const char *format, ...) ISC_FORMAT_PRINTF(1, 2);
|