diff options
author | Charlie Savage <cfis@zerista.com> | 2011-08-24 12:37:15 -0600 |
---|---|---|
committer | Charlie Savage <cfis@zerista.com> | 2011-08-24 16:47:55 -0600 |
commit | d299173c6c7b096ec3ddb3cb54c7ca33bfa00085 (patch) | |
tree | 8b63dccf64eed1d068b4b97856706555692564f4 /ext/ffi_c/ClosurePool.c | |
parent | a33700e41c211bd0b2f50dc87f4dede219845326 (diff) | |
download | ffi-d299173c6c7b096ec3ddb3cb54c7ca33bfa00085.tar.gz |
Pool is allocated using ruby's xalloc method but is the destroyed via free. That means it could be freed by a different runtime library on windows, which is a big no-no and causes a heap corruption error on debug builds. pool should instead be freed using ruby's xfree method.
Diffstat (limited to 'ext/ffi_c/ClosurePool.c')
-rw-r--r-- | ext/ffi_c/ClosurePool.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/ffi_c/ClosurePool.c b/ext/ffi_c/ClosurePool.c index 1efbe3a..7cff4a1 100644 --- a/ext/ffi_c/ClosurePool.c +++ b/ext/ffi_c/ClosurePool.c @@ -103,7 +103,7 @@ cleanup_closure_pool(ClosurePool* pool) free(memory); memory = next; } - free(pool); + xfree(pool); } void |