Re: [Openvpn-devel] [PATCH] fix warnings in event.c when building for win32-64

2012-02-21 Thread David Sommerseth
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On 18/08/11 14:12, Heiko Hund wrote:
> 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  --- event.c |8
>  1 files changed, 4 insertions(+), 4 deletions(-)
> 

Cleaning up some old patches which had slipped the patch queue.  Applied
to master and new master branch is pushed to -stable and -testing trees.

commit 3c19fcc2099d8ddf6bfeec6550d4e3cb1cbf3431
Author: Heiko Hund 
List-Post: openvpn-devel@lists.sourceforge.net
Date:   Thu Aug 18 12:12:11 2011 +

fix warnings in event.c when building for win32-64

Signed-off-by: Heiko Hund 
Acked-by: James Yonan 
URL: http://article.gmane.org/gmane.network.openvpn.devel/4979
Signed-off-by: David Sommerseth 


kind regards,

David Sommerseth
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAk9DoJkACgkQDC186MBRfrrN8gCfdtscvYfl3S4tMAbI3/lPUYmg
COwAmwQyA/13DWVRppNs9Cleo1ov+sdJ
=VUzA
-END PGP SIGNATURE-



[Openvpn-devel] [PATCH] fix warnings in event.c when building for win32-64

2011-08-18 Thread Heiko Hund
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 
---
 event.c |8 
 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);
   }
-- 
1.7.5.4