summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWillem Toorop <willem@nlnetlabs.nl>2014-08-21 17:14:08 +0200
committerWillem Toorop <willem@nlnetlabs.nl>2014-08-21 17:14:08 +0200
commitf84597e8dccfb2455ac0e335c8102ae936777c28 (patch)
tree891180731e1532f4016de6341588f99877de1b9f
parent9f370d0521890360aa9f00aed629917d7ae6a793 (diff)
downloadldns-f84597e8dccfb2455ac0e335c8102ae936777c28.tar.gz
Lint things
-rw-r--r--host2wire.c2
-rw-r--r--rr.c4
-rw-r--r--wire2host.c2
3 files changed, 4 insertions, 4 deletions
diff --git a/host2wire.c b/host2wire.c
index b9351d15..b88baadf 100644
--- a/host2wire.c
+++ b/host2wire.c
@@ -56,7 +56,7 @@ ldns_dname2buffer_wire_compress(ldns_buffer *buffer, const ldns_rdf *name, ldns_
if((node = ldns_rbtree_search(compression_data, ldns_rdf_data(name))) != NULL)
{
/* Found */
- uint16_t position = (0xC000 | (uint16_t) (intptr_t) node->data);
+ uint16_t position = (uint16_t) (intptr_t) node->data | 0xC000;
if (ldns_buffer_reserve(buffer, 2))
{
ldns_buffer_write_u16(buffer, position);
diff --git a/rr.c b/rr.c
index 671c4ebd..d51c4af2 100644
--- a/rr.c
+++ b/rr.c
@@ -671,9 +671,9 @@ ldns_rr_new_question_frm_str(ldns_rr **newrr, const char *str,
}
static int
-ldns_rr_is_whitespace_line(char* line, int line_len)
+ldns_rr_is_whitespace_line(char* line, ssize_t line_len)
{
- int i;
+ ssize_t i;
for (i = 0; i < line_len; i++) {
if (!isspace((int)line[i])) {
return 0;
diff --git a/wire2host.c b/wire2host.c
index a36fd344..386c3507 100644
--- a/wire2host.c
+++ b/wire2host.c
@@ -405,7 +405,7 @@ ldns_wire2pkt(ldns_pkt **packet_p, const uint8_t *wire, size_t max)
ldns_rr *rr;
ldns_pkt *packet = ldns_pkt_new();
ldns_status status = LDNS_STATUS_OK;
- int have_edns = 0;
+ uint8_t have_edns = 0;
uint8_t data[4];