Fix various little bugs and loosen up various warnings
Change-Id: Iead48ac030290290c7c448b6f72a31380c2e8326
diff --git a/third_party/libevent/ht-internal.h b/third_party/libevent/ht-internal.h
index 4673825..a56c4a6 100644
--- a/third_party/libevent/ht-internal.h
+++ b/third_party/libevent/ht-internal.h
@@ -137,7 +137,7 @@
/* Helper: returns a pointer to the right location in the table \
* 'head' to find or insert the element 'elm'. */ \
static inline struct type ** \
- _##name##_HT_FIND_P(struct name *head, struct type *elm) \
+ _##name##_HT_FIND_P(const struct name *head, struct type *elm) \
{ \
struct type **p; \
if (!head->hth_table) \
@@ -156,7 +156,7 @@
name##_HT_FIND(const struct name *head, struct type *elm) \
{ \
struct type **p; \
- struct name *h = (struct name *) head; \
+ const struct name *h = (const struct name *) head; \
_HT_SET_HASH(elm, field, hashfn); \
p = _##name##_HT_FIND_P(h, elm); \
return p ? *p : NULL; \