On Mon, Oct 6, 2008 at 7:08 PM, Peter Wehrfritz <[EMAIL PROTECTED]>wrote:

> Enlightenment SVN schrieb:
> > Log:
> >   Another step toward IPv6 support with more cleanup.
> >
> >   Patch from Arnaud de Turckheim.
> >
> >
> > Author:       cedric
> > Date:         2008-10-06 09:40:01 -0700 (Mon, 06 Oct 2008)
> > New Revision: 36483
> >
> > Modified:
> >   trunk/ecore/src/lib/ecore_con/ecore_con.c
> trunk/ecore/src/lib/ecore_con/ecore_con_info.c
> >
> > Modified: trunk/ecore/src/lib/ecore_con/ecore_con.c
> > ===================================================================
> > --- trunk/ecore/src/lib/ecore_con/ecore_con.c 2008-10-06 15:58:21 UTC
> (rev 36482)
> > +++ trunk/ecore/src/lib/ecore_con/ecore_con.c 2008-10-06 16:40:01 UTC
> (rev 36483)
> > @@ -26,21 +26,23 @@
> >  # include <winsock2.h>
> >  #endif
> >
> > -static void _ecore_con_cb_dns_lookup(void *data, struct hostent *he);
> > -static void _ecore_con_cb_udp_dns_lookup(void *data, struct hostent
> *he);
> >  static void _ecore_con_cb_tcp_connect(void *data, Ecore_Con_Netinfo
> *info);
> >  static void _ecore_con_cb_udp_connect(void *data, Ecore_Con_Netinfo
> *info);
> >  static void _ecore_con_cb_tcp_listen(void *data, Ecore_Con_Netinfo
> *info);
> >  static void _ecore_con_cb_udp_listen(void *data, Ecore_Con_Netinfo
> *info);
> > +
> >  static void _ecore_con_server_free(Ecore_Con_Server *svr);
> >  static void _ecore_con_client_free(Ecore_Con_Client *cl);
> > +
> >  static int _ecore_con_svr_handler(void *data, Ecore_Fd_Handler
> *fd_handler);
> >  static int _ecore_con_cl_handler(void *data, Ecore_Fd_Handler
> *fd_handler);
> >  static int _ecore_con_cl_udp_handler(void *data, Ecore_Fd_Handler
> *fd_handler);
> >  static int _ecore_con_svr_udp_handler(void *data, Ecore_Fd_Handler
> *fd_handler);
> >  static int _ecore_con_svr_cl_handler(void *data, Ecore_Fd_Handler
> *fd_handler);
> > +
> >  static void _ecore_con_server_flush(Ecore_Con_Server *svr);
> >  static void _ecore_con_client_flush(Ecore_Con_Client *cl);
> > +
> >  static void _ecore_con_event_client_add_free(void *data, void *ev);
> >  static void _ecore_con_event_client_del_free(void *data, void *ev);
> >  static void _ecore_con_event_client_data_free(void *data, void *ev);
> > @@ -57,8 +59,25 @@
> >
> >  static Ecore_List *servers = NULL;
> >  static int init_count = 0;
> > +
> >  #if USE_OPENSSL
> >  static int ssl_init_count = 0;
> > +static int _ecore_con_init_ssl(Ecore_Con_Server *svr);
> > +static int _ecore_con_shutdown_ssl(Ecore_Con_Server *svr);
> > +static int _ecore_con_free_ssl(Ecore_Con_Server *svr);
> > +
> > +# define INIT_SSL(svr) _ecore_con_init_ssl(svr)
> > +# define SHUTDOWN_SSL(svr) _ecore_con_shutdown_ssl(svr)
> > +# define FREE_SSL(svr) _ecore_con_free_ssl(svr)
> > +# define UNSET_SSL(svr)              \
> > +  do {                               \
> > +    svr->ssl = NULL;         \
> > +    svr->ssl_ctx = NULL;     \
> > +  } while (0);
> >
>
> The point of using do {} while(0) in macros, fades away if you append a
> semicolon.

I'll remove the semicolon, sorry about that.

>
> > +#else
> > +# define INIT_SSL(svr) 0
> > +# define SHUTDOWN_SSL(svr) 0
> > +# define FREE_SSL(svr) 0
> >  #endi
> I haven't read the full code, but I think you are missing the
> UNSET_SSL() for the !OPENSSL case.

We don't need UNSET_SSL() to be define when !USE_OPENSSL.
INIT_SSL, SHUTDOWN_SSL and FREE_SSL have to be define to 0 because these
macros are used in if tests.

>
>
> Peter
>
> -------------------------------------------------------------------------
> This SF.Net email is sponsored by the Moblin Your Move Developer's
> challenge
> Build the coolest Linux based applications with Moblin SDK & win great
> prizes
> Grand prize is a trip for two to an Open Source event anywhere in the world
> http://moblin-contest.org/redirect.php?banner_id=100&url=/
> _______________________________________________
> enlightenment-devel mailing list
> enlightenment-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
>



-- 
Arnaud de Turckheim
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel

Reply via email to