Commit fe47f41b authored by Bob Halley's avatar Bob Halley
Browse files

eliminate compiler warnings (signed vs. unsigned)

parent 1c969834
......@@ -58,7 +58,7 @@ dns_db_t *db;
/*
* For debugging only... XXX
*/
void dump_packet(char *buf, u_int len);
void dump_packet(unsigned char *buf, u_int len);
static void
makename(isc_mem_t *mctx, char *text, dns_name_t *name, dns_name_t *origin) {
......
......@@ -54,7 +54,7 @@ typedef struct dns_message {
} dns_message_t;
void
dump_packet(char *buf, u_int len);
dump_packet(unsigned char *buf, u_int len);
dns_result_t
resolve_packet(dns_db_t *db, isc_buffer_t *source, isc_buffer_t *target);
......@@ -67,7 +67,7 @@ void getmessage(dns_message_t *message, isc_buffer_t *source,
dns_result_t printmessage(dns_message_t *message);
void
dump_packet(char *buf, u_int len)
dump_packet(unsigned char *buf, u_int len)
{
extern dns_decompress_t dctx;
extern unsigned int rdcount, rlcount, ncount;
......
......@@ -1360,7 +1360,8 @@ static int
cmp_label(dns_label_t *a, dns_label_t *b) {
int i;
i = strncasecmp(a->base, b->base, MIN(a->length, b->length));
i = strncasecmp((char *)a->base, (char *)b->base,
MIN(a->length, b->length));
if (i == 0 && a->length != b->length)
return(a->length < b->length ? -1 : 1);
......
......@@ -427,7 +427,7 @@ add_rdataset_callback(dns_name_t *name, dns_rdataset_t *rdataset,
static dns_result_t
load(dns_db_t *db, char *filename) {
dns_rbtdb_t *rbtdb = (dns_rbtdb_t *)db;
unsigned int soacount, nscount;
int soacount, nscount;
REQUIRE(VALID_RBTDB(rbtdb));
......
......@@ -15,7 +15,7 @@
* SOFTWARE.
*/
/* $Id: rdata.c,v 1.19 1999/02/01 21:34:51 marka Exp $ */
/* $Id: rdata.c,v 1.20 1999/02/02 01:18:19 halley Exp $ */
#include <config.h>
......@@ -433,12 +433,12 @@ txt_totext(isc_region_t *source, isc_buffer_t *target) {
unsigned int tl;
unsigned int n;
unsigned char *sp;
unsigned char *tp;
char *tp;
isc_region_t region;
isc_buffer_available(target, &region);
sp = source->base;
tp = region.base;
tp = (char *)region.base;
tl = region.length;
n = *sp++;
......@@ -473,7 +473,7 @@ txt_totext(isc_region_t *source, isc_buffer_t *target) {
return (DNS_R_NOSPACE);
*tp++ = '"';
tl--;
isc_buffer_add(target, tp - region.base);
isc_buffer_add(target, tp - (char *)region.base);
isc_region_consume(source, *source->base + 1);
return (DNS_R_SUCCESS);
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment