diff options
-rw-r--r-- | ChangeLog | 4 | ||||
-rw-r--r-- | pack.c | 4 |
2 files changed, 6 insertions, 2 deletions
@@ -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. @@ -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]; \ } \ |