Subject: | Fix for 64 bit |
Calling the FFI::call function on 64 bit usually causes a segmentation fault, because it is using an int type to store a pointer.
iscah% perl -Mblib t/basic.t
1..5
# Running under perl version 5.020001 for linux
# Current time local: Fri Feb 27 11:17:34 2015
# Current time GMT: Fri Feb 27 16:17:34 2015
# Using Test.pm version 1.26
Segmentation fault
The attached patch should fix the problem.
Subject: | patch.diff |
diff --git a/FFI.xs b/FFI.xs
index 0afd442..a8b274f 100644
--- a/FFI.xs
+++ b/FFI.xs
@@ -168,7 +168,7 @@ MODULE = FFI PACKAGE = FFI
void
call(addr, sig, ...)
- void *addr;
+ int addr;
char *sig;
PREINIT: