I have custom C bindings called from Matlab and sometimes I get a segmentation fault. How can I identify in my source code what the corresponding statement is producing the SEGFAULT?
My C function is called Pairing in the source file Pairing.c
Stack Trace (from fault):
[ 0] 0x00007fff6bc76d00 Pairing.mexa64+00015616
[ 1] 0x00007fff6bc74330 Pairing.mexa64+00004912 mexFunction+00001862
[ 2] 0x00007fffe2b4f213 MATLAB/R2020a/bin/glnxa64/libmex.so+00582163
The result of nm -a Pairing.mexa64 | grep ' N '
is
0000000000000000 N .debug_abbrev
0000000000000000 N .debug_aranges
0000000000000000 N .debug_info
0000000000000000 N .debug_line
0000000000000000 N .debug_str