diff options
author | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2011-03-09 18:01:11 +0000 |
---|---|---|
committer | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2011-03-09 18:01:11 +0000 |
commit | 08c07a215d3d4b5e26293d9d52bc06b486f15844 (patch) | |
tree | 04224b95a9dee0cb724ecede3875709bb161acc4 /ext | |
parent | af1460d6701c530633b008e55bc2a81284a50744 (diff) | |
download | ruby-08c07a215d3d4b5e26293d9d52bc06b486f15844.tar.gz |
* ext/openssl/ossl_ssl.c: parenthesize macro arguments.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31080 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext')
-rw-r--r-- | ext/openssl/ossl_ssl.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/ext/openssl/ossl_ssl.c b/ext/openssl/ossl_ssl.c index e26be8a365..e5cce0f0e8 100644 --- a/ext/openssl/ossl_ssl.c +++ b/ext/openssl/ossl_ssl.c @@ -16,12 +16,12 @@ # include <unistd.h> /* for read(), and write() */ #endif -#define numberof(ary) (int)(sizeof(ary)/sizeof(ary[0])) +#define numberof(ary) (int)(sizeof(ary)/sizeof((ary)[0])) #ifdef _WIN32 # define TO_SOCKET(s) _get_osfhandle(s) #else -# define TO_SOCKET(s) s +# define TO_SOCKET(s) (s) #endif VALUE mSSL; @@ -1064,9 +1064,9 @@ ossl_ssl_setup(VALUE self) } #ifdef _WIN32 -#define ssl_get_error(ssl, ret) (errno = rb_w32_map_errno(WSAGetLastError()), SSL_get_error(ssl, ret)) +#define ssl_get_error(ssl, ret) (errno = rb_w32_map_errno(WSAGetLastError()), SSL_get_error((ssl), (ret))) #else -#define ssl_get_error(ssl, ret) SSL_get_error(ssl, ret) +#define ssl_get_error(ssl, ret) SSL_get_error((ssl), (ret)) #endif static void |