summaryrefslogtreecommitdiff
path: root/gc.c
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2000-03-13 09:15:46 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2000-03-13 09:15:46 +0000
commit844e89897c44a6c3486b27497e3df015e42813cf (patch)
tree97b96ee9153d244b65645ecb6547676c8e87e36d /gc.c
parent13adec97c9c4ad2aa8ea3edfd9c65710b703f51f (diff)
2000-03-13
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_4@639 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'gc.c')
-rw-r--r--gc.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/gc.c b/gc.c
index a649a20e84..879adf27e9 100644
--- a/gc.c
+++ b/gc.c
@@ -50,7 +50,6 @@ static unsigned long malloc_memories = 0;
static unsigned long alloc_objects = 0;
static int malloc_called = 0;
-static int free_called = 0;
#ifndef xmalloc
void *
@@ -115,12 +114,11 @@ xrealloc(ptr, size)
return mem;
}
-static void
+void
xfree(x)
void *x;
{
- free_called++;
- free(x);
+ if (x) free(x);
}
#endif