summaryrefslogtreecommitdiff
path: root/common/compat.c
diff options
context:
space:
mode:
Diffstat (limited to 'common/compat.c')
-rw-r--r--common/compat.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/common/compat.c b/common/compat.c
index ff8d527..e1bddef 100644
--- a/common/compat.c
+++ b/common/compat.c
@@ -443,13 +443,14 @@ char* strlwr(char *string)
#ifndef HAVE_REALLOCF
+#undef reallocf
-void* reallocf(void* ptr, size_t size)
+void* reallocf(void* pt, size_t sz)
{
- void* ret = realloc(ptr, size);
+ void* ret = realloc(pt, sz);
- if(!ret && size)
- free(ptr);
+ if(!ret && sz)
+ free(pt);
return ret;
}