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