summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog4
-rw-r--r--ext/sdbm/init.c8
2 files changed, 8 insertions, 4 deletions
diff --git a/ChangeLog b/ChangeLog
index 0c26ecc..4ddb96a 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+Fri Mar 25 21:56:10 2011 Tanaka Akira <akr@fsij.org>
+
+ * ext/sdbm/init.c: parenthesize macro arguments.
+
Fri Mar 25 19:39:40 2011 Ben Walton <bwalton@artsci.utoronto.ca>
* test/test_syslog.rb:
diff --git a/ext/sdbm/init.c b/ext/sdbm/init.c
index 6a02e1e..7ba59c4 100644
--- a/ext/sdbm/init.c
+++ b/ext/sdbm/init.c
@@ -29,13 +29,13 @@ closed_sdbm()
}
#define GetDBM(obj, dbmp) {\
- Data_Get_Struct(obj, struct dbmdata, dbmp);\
- if (dbmp == 0) closed_sdbm();\
- if (dbmp->di_dbm == 0) closed_sdbm();\
+ Data_Get_Struct((obj), struct dbmdata, (dbmp));\
+ if ((dbmp) == 0) closed_sdbm();\
+ if ((dbmp)->di_dbm == 0) closed_sdbm();\
}
#define GetDBM2(obj, data, dbm) {\
- GetDBM(obj, data);\
+ GetDBM((obj), (data));\
(dbm) = dbmp->di_dbm;\
}