summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHeiko Hund <heiko.hund@sophos.com>2011-08-18 12:12:11 +0000
committerDavid Sommerseth <davids@redhat.com>2012-02-21 14:45:03 +0100
commit3c19fcc2099d8ddf6bfeec6550d4e3cb1cbf3431 (patch)
tree9c4db346d27369533f494f8107bd06a403fd64c9
parent14a382a3f1c70fdbc822bcad27096040ed394661 (diff)
fix warnings in event.c when building for win32-64
When compiling for 64-bit Windows gcc warns about "cast from pointer to integer of different size" on two occasions in file event.c, due to invalid casting. This patch removes the type casts and uses the correct format specifier instead. Signed-off-by: Heiko Hund <heiko.hund@sophos.com> Acked-by: James Yonan <james@openvpn.net> URL: http://article.gmane.org/gmane.network.openvpn.devel/4979 Signed-off-by: David Sommerseth <davids@redhat.com>
-rw-r--r--event.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/event.c b/event.c
index 51b17b3..b6ed673 100644
--- a/event.c
+++ b/event.c
@@ -214,9 +214,9 @@ we_ctl (struct event_set *es, event_t event, unsigned int rwflags, void *arg)
{
struct we_set *wes = (struct we_set *) es;
- dmsg (D_EVENT_WAIT, "WE_CTL n=%d ev=0x%08x rwflags=0x%04x arg=" ptr_format,
+ dmsg (D_EVENT_WAIT, "WE_CTL n=%d ev=%p rwflags=0x%04x arg=" ptr_format,
wes->n_events,
- (unsigned int)event,
+ event,
rwflags,
(ptr_type)arg);
@@ -344,9 +344,9 @@ we_wait (struct event_set *es, const struct timeval *tv, struct event_set_return
if (check_debug_level (D_EVENT_WAIT)) {
int i;
for (i = 0; i < wes->n_events; ++i)
- dmsg (D_EVENT_WAIT, "[%d] ev=0x%08x rwflags=0x%04x arg=" ptr_format,
+ dmsg (D_EVENT_WAIT, "[%d] ev=%p rwflags=0x%04x arg=" ptr_format,
i,
- (unsigned int)wes->events[i],
+ wes->events[i],
wes->esr[i].rwflags,
(ptr_type)wes->esr[i].arg);
}