summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2006-09-03 02:13:52 +0000
committerNick Mathewson <nickm@torproject.org>2006-09-03 02:13:52 +0000
commitb40e639f15d413ef159742ae05f895c374c88a46 (patch)
tree206e01eadef0bc59f12fa563bc49bf3bc5e774ee
parent4392aa9dd45606c902f24e399a7d097864892bee (diff)
downloadtor-b40e639f15d413ef159742ae05f895c374c88a46.tar.gz
tor-b40e639f15d413ef159742ae05f895c374c88a46.zip
r8708@Kushana: nickm | 2006-09-02 20:34:15 -0400
Fix warnings reported by weasel when compiling Tor on Debian woody. svn:r8318
-rw-r--r--src/or/eventdns.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/or/eventdns.c b/src/or/eventdns.c
index 31c569af1b..f7489d968b 100644
--- a/src/or/eventdns.c
+++ b/src/or/eventdns.c
@@ -291,11 +291,13 @@
#undef MIN
#define MIN(a,b) ((a)<(b)?(a):(b))
+#if 0
#ifdef __USE_ISOC99B
// libevent doesn't work without this
typedef uint8_t u_char;
typedef unsigned int uint;
#endif
+#endif
#include <event.h>
#define u64 uint64_t
@@ -317,7 +319,7 @@ typedef unsigned int uint;
struct request {
u8 *request; // the dns packet data
- uint request_len;
+ unsigned int request_len;
u8 reissue_count;
u8 tx_count; // the number of times that this packet has been sent
u8 request_type; // TYPE_PTR or TYPE_A
@@ -858,7 +860,7 @@ reply_parse(u8 *packet, int length) {
u32 ttl, ttl_r = 0xffffffff;
struct reply reply;
struct request *req;
- uint i;
+ unsigned int i;
GET16(trans_id);
GET16(flags);
@@ -1116,7 +1118,7 @@ dnsname_to_labels(u8 *const buf, const char *name, const int name_len) { \
const char *const start = name;
name = strchr(name, '.');
if (!name) {
- const uint label_len = end - start;
+ const unsigned int label_len = end - start;
if (label_len > 63) return -1;
buf[j++] = label_len;
@@ -1125,7 +1127,7 @@ dnsname_to_labels(u8 *const buf, const char *name, const int name_len) { \
break;
} else {
// append length of the label.
- const uint label_len = name - start;
+ const unsigned int label_len = name - start;
if (label_len > 63) return -1;
buf[j++] = label_len;