summaryrefslogtreecommitdiffstats
path: root/ext
diff options
context:
space:
mode:
authorakr <akr@ruby-lang.org>2011-03-16 21:23:31 +0000
committerakr <akr@ruby-lang.org>2011-03-16 21:23:31 +0000
commit07de410661ce1ef3a56ac6ee421a687a2aa21f68 (patch)
tree2dcd953a2dfa203aae38933f89b23d28584bb3f6 /ext
parent00b28d3089ba38a0d52c6106e563a5fff4e6e84f (diff)
downloadruby-openssl-history-07de410661ce1ef3a56ac6ee421a687a2aa21f68.tar.gz
* ext/openssl/ossl_x509name.c: parenthesize macro arguments.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31118 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext')
-rw-r--r--ext/openssl/ossl_x509name.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/ext/openssl/ossl_x509name.c b/ext/openssl/ossl_x509name.c
index 417d042..df533e8 100644
--- a/ext/openssl/ossl_x509name.c
+++ b/ext/openssl/ossl_x509name.c
@@ -11,20 +11,20 @@
#include "ossl.h"
#define WrapX509Name(klass, obj, name) do { \
- if (!name) { \
+ if (!(name)) { \
ossl_raise(rb_eRuntimeError, "Name wasn't initialized."); \
} \
- obj = Data_Wrap_Struct(klass, 0, X509_NAME_free, name); \
+ (obj) = Data_Wrap_Struct((klass), 0, X509_NAME_free, (name)); \
} while (0)
#define GetX509Name(obj, name) do { \
- Data_Get_Struct(obj, X509_NAME, name); \
- if (!name) { \
+ Data_Get_Struct((obj), X509_NAME, (name)); \
+ if (!(name)) { \
ossl_raise(rb_eRuntimeError, "Name wasn't initialized."); \
} \
} while (0)
#define SafeGetX509Name(obj, name) do { \
- OSSL_Check_Kind(obj, cX509Name); \
- GetX509Name(obj, name); \
+ OSSL_Check_Kind((obj), cX509Name); \
+ GetX509Name((obj), (name)); \
} while (0)
#define OBJECT_TYPE_TEMPLATE \
@@ -89,7 +89,7 @@ ossl_x509name_alloc(VALUE klass)
static int id_aref;
static VALUE ossl_x509name_add_entry(int, VALUE*, VALUE);
-#define rb_aref(obj, key) rb_funcall(obj, id_aref, 1, key)
+#define rb_aref(obj, key) rb_funcall((obj), id_aref, 1, (key))
static VALUE
ossl_x509name_init_i(VALUE i, VALUE args)