diff --git a/ChangeLog b/ChangeLog index 5a2843379..e13bf3e03 100644 --- a/ChangeLog +++ b/ChangeLog @@ -11,6 +11,7 @@ Bug fixes * Fixed bug resulting in failure to send the last certificate in the chain in ssl_write_certificate() and ssl_write_certificate_request() (Found by fatbob) + * Added small fixes for compiler warnings on a Mac = Version 0.12.1 released on 2009-10-04 Changes diff --git a/library/debug.c b/library/debug.c index 33151db0d..58bb816b2 100644 --- a/library/debug.c +++ b/library/debug.c @@ -139,8 +139,9 @@ void debug_print_mpi( const ssl_context *ssl, int level, if( X->p[n] != 0 ) break; - snprintf( str, maxlen, "%s(%04d): value of '%s' (%d bits) is:\n", - file, line, text, ((n + 1) * sizeof( t_int )) << 3 ); + snprintf( str, maxlen, "%s(%04d): value of '%s' (%lu bits) is:\n", + file, line, text, + (unsigned long) ((n + 1) * sizeof( t_int )) << 3 ); str[maxlen] = '\0'; ssl->f_dbg( ssl->p_dbg, level, str ); diff --git a/library/net.c b/library/net.c index a94ebf794..e3b173855 100644 --- a/library/net.c +++ b/library/net.c @@ -226,7 +226,7 @@ int net_accept( int bind_fd, int *client_fd, void *client_ip ) { struct sockaddr_in client_addr; -#if defined(__socklen_t_defined) +#if defined(__socklen_t_defined) || defined(_SOCKLEN_T) socklen_t n = (socklen_t) sizeof( client_addr ); #else int n = (int) sizeof( client_addr );