This is the mail archive of the libffi-discuss@sourceware.org mailing list for the libffi project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: pass by value and also snprintf()


The GDB result (using snprintf this time):

(gdb)
37              if (ffi_prep_cif_var(&cif, FFI_DEFAULT_ABI, 3, 5,
(gdb)
41                      ffi_call(&cif, fn, &ret_val, values);
(gdb)

Program received signal SIGSEGV, Segmentation fault.
0x00007ffff787f562 in vsnprintf () from /lib/x86_64-linux-gnu/libc.so.6
(gdb) bt
#0  0x00007ffff787f562 in vsnprintf () from /lib/x86_64-linux-gnu/libc.so.6
#1  0x00007ffff7861532 in snprintf () from /lib/x86_64-linux-gnu/libc.so.6
#2  0x00007ffff7bd7adc in ffi_call_unix64 () from
/usr/lib/x86_64-linux-gnu/libffi.so.6
#3  0x00007ffff7bd740c in ffi_call () from /usr/lib/x86_64-linux-gnu/libffi.so.6
#4  0x0000000000400ac0 in main (argc=1, argv=0x7fffffffe488) at ffi-test.c:41


If I link against the -O0 -ggdb3 version of libffi, what can I do to
help diagnose?


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]