mirror of
https://gitlab.isc.org/isc-projects/bind9
synced 2025-08-30 22:15:20 +00:00
signed vs unsigned fixes
This commit is contained in:
@@ -233,7 +233,7 @@ help(void) {
|
||||
* Callback from dighost.c to print the received message.
|
||||
*/
|
||||
static void
|
||||
received(int bytes, isc_sockaddr_t *from, dig_query_t *query) {
|
||||
received(unsigned int bytes, isc_sockaddr_t *from, dig_query_t *query) {
|
||||
isc_uint64_t diff;
|
||||
time_t tnow;
|
||||
struct tm tmnow;
|
||||
@@ -1311,11 +1311,11 @@ plus_option(const char *option, isc_boolean_t is_batchfile,
|
||||
|
||||
result = parse_uint(&splitwidth, value,
|
||||
1023, "split");
|
||||
if (splitwidth % 4 != 0) {
|
||||
if ((splitwidth % 4) != 0U) {
|
||||
splitwidth = ((splitwidth + 3) / 4) * 4;
|
||||
fprintf(stderr, ";; Warning, split must be "
|
||||
"a multiple of 4; adjusting "
|
||||
"to %d\n", splitwidth);
|
||||
"to %u\n", splitwidth);
|
||||
}
|
||||
/*
|
||||
* There is an adjustment done in the
|
||||
|
@@ -202,7 +202,7 @@ isc_result_t
|
||||
isc_boolean_t headers);
|
||||
|
||||
void
|
||||
(*dighost_received)(int bytes, isc_sockaddr_t *from, dig_query_t *query);
|
||||
(*dighost_received)(unsigned int bytes, isc_sockaddr_t *from, dig_query_t *query);
|
||||
|
||||
void
|
||||
(*dighost_trying)(char *frm, dig_lookup_t *lookup);
|
||||
@@ -266,7 +266,7 @@ hex_dump(isc_buffer_t *b) {
|
||||
|
||||
isc_buffer_usedregion(b, &r);
|
||||
|
||||
printf("%d bytes\n", r.length);
|
||||
printf("%u bytes\n", r.length);
|
||||
for (len = 0; len < r.length; len++) {
|
||||
printf("%02x ", r.base[len]);
|
||||
if (len % 16 == 15) {
|
||||
@@ -437,7 +437,7 @@ debug(const char *format, ...) {
|
||||
fflush(stdout);
|
||||
if (debugtiming) {
|
||||
TIME_NOW(&t);
|
||||
fprintf(stderr, "%d.%06d: ", isc_time_seconds(&t),
|
||||
fprintf(stderr, "%u.%06u: ", isc_time_seconds(&t),
|
||||
isc_time_nanoseconds(&t) / 1000);
|
||||
}
|
||||
va_start(args, format);
|
||||
@@ -3738,7 +3738,7 @@ recv_done(isc_task_t *task, isc_event_t *event) {
|
||||
*/
|
||||
if (l->comments)
|
||||
printf(";; BADVERS, retrying with EDNS version %u.\n",
|
||||
newedns);
|
||||
(unsigned int)newedns);
|
||||
l->edns = newedns;
|
||||
n = requeue_lookup(l, ISC_TRUE);
|
||||
if (l->trace && l->trace_root)
|
||||
|
@@ -169,7 +169,7 @@ host_shutdown(void) {
|
||||
}
|
||||
|
||||
static void
|
||||
received(int bytes, isc_sockaddr_t *from, dig_query_t *query) {
|
||||
received(unsigned int bytes, isc_sockaddr_t *from, dig_query_t *query) {
|
||||
isc_time_t now;
|
||||
int diff;
|
||||
|
||||
|
@@ -382,7 +382,7 @@ extern isc_result_t
|
||||
*/
|
||||
|
||||
extern void
|
||||
(*dighost_received)(int bytes, isc_sockaddr_t *from, dig_query_t *query);
|
||||
(*dighost_received)(unsigned int bytes, isc_sockaddr_t *from, dig_query_t *query);
|
||||
/*%<
|
||||
* Print a message about where and when the response
|
||||
* was received from, like the final comment in the
|
||||
|
@@ -387,7 +387,7 @@ detailsection(dig_query_t *query, dns_message_t *msg, isc_boolean_t headers,
|
||||
}
|
||||
|
||||
static void
|
||||
received(int bytes, isc_sockaddr_t *from, dig_query_t *query)
|
||||
received(unsigned int bytes, isc_sockaddr_t *from, dig_query_t *query)
|
||||
{
|
||||
UNUSED(bytes);
|
||||
UNUSED(from);
|
||||
@@ -549,7 +549,7 @@ show_settings(isc_boolean_t full, isc_boolean_t serv_only) {
|
||||
printf(" %s\t\t%s\n",
|
||||
usesearch ? "search" : "nosearch",
|
||||
recurse ? "recurse" : "norecurse");
|
||||
printf(" timeout = %d\t\tretry = %d\tport = %d\tndots = %d\n",
|
||||
printf(" timeout = %u\t\tretry = %d\tport = %u\tndots = %d\n",
|
||||
timeout, tries, port, ndots);
|
||||
printf(" querytype = %-8s\tclass = %s\n", deftype, defclass);
|
||||
printf(" srchlist = ");
|
||||
|
Reference in New Issue
Block a user