summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2006-07-17 13:55:04 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2006-07-17 13:55:04 +0000
commitfd3690d34b82757643d45c88b7450520d7c7be93 (patch)
treeac52f5088dbd6ea03e5bc069f2f4434ad640183d
parentf2cfba14101d408f7ee7d2c823465ea00a854293 (diff)
* pack.c (define_swapx): should not use plain malloc.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10545 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--ChangeLog4
-rw-r--r--pack.c4
2 files changed, 6 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index cbdc2ba..d5dc160 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+Mon Jul 17 13:43:05 2006 Yukihiro Matsumoto <matz@ruby-lang.org>
+
+ * pack.c (define_swapx): should not use plain malloc.
+
Mon Jul 17 12:58:41 2006 WATANABE Hirofumi <eban@ruby-lang.org>
* configure.in: should use ac_cv_lib_dl_dlopen=no on MinGW.
diff --git a/pack.c b/pack.c
index efd69c9..d031f59 100644
--- a/pack.c
+++ b/pack.c
@@ -60,10 +60,10 @@ TOKEN_PASTE(swap,x)(z) \
unsigned char *s, *t; \
int i; \
\
- zp = malloc(sizeof(xtype)); \
+ zp = xmalloc(sizeof(xtype)); \
*zp = z; \
s = (unsigned char*)zp; \
- t = malloc(sizeof(xtype)); \
+ t = xmalloc(sizeof(xtype)); \
for (i=0; i<sizeof(xtype); i++) { \
t[sizeof(xtype)-i-1] = s[i]; \
} \