Subject: OT: PJSIP: Segmentation fault

From: Filippo Zangheri <[email-masked]>
Date: Fri, 04 Jul 2008 12:14:52 +0200

Hi all,

I'm trying to test pjsip-0.9.0 on a Debian with vanilla kernel 2.6.25.9
(without IPv6 support).

I'm posting my problem to this mailing list in the hope that some kernel
guru helps me shed a little light on the problem I'm experiencing, which
- I think - is closely related to Linux network internals.

I'm getting a Segmentation fault but I'm not able to determine the cause.
Avoiding to call pj_enum_ip_interface() completely solves the problem.

Briefly:

I've double-checked the parameters passed to that function; I've printed
messages to standard output to determine where the error occurrs, but it
seems that the cause is not inside the function...

Can you spot anything wrong in the following strace log?

=== STRACE LOG ('strace -rif -o strace.log ./stateful_proxy-i686-pc-linux-gnu') ===

15191 0.000000 [b7f8e424] execve("./stateful_proxy-i686-pc-linux-gnu", ["./stateful_proxy-i686-pc-linux-g"...], [/* 35 vars */]) = 0
15191 0.000248 [b7efc9ed] uname({sys="Linux", node="asus-laptop", ...}) = 0
15191 0.000122 [b7efbedb] brk(0) = 0x8080000
15191 0.000044 [b7efc781] access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
15191 0.000059 [b7efc933] mmap2(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb7ee9000
15191 0.000038 [b7efc781] access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory)
15191 0.000051 [b7efc644] open("/etc/ld.so.cache", O_RDONLY) = 3
15191 0.000039 [b7efc60e] fstat64(3, {st_mode=S_IFREG|0644, st_size=71336, ...}) = 0
15191 0.000066 [b7efc933] mmap2(NULL, 71336, PROT_READ, MAP_PRIVATE, 3, 0) = 0xb7ed7000
15191 0.000030 [b7efc67d] close(3) = 0
15191 0.000029 [b7efc781] access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
15191 0.000049 [b7efc644] open("/lib/tls/i686/cmov/libm.so.6", O_RDONLY) = 3
15191 0.000047 [b7efc6c4] read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0`3\0\000"..., 512) = 512
15191 0.000049 [b7efc60e] fstat64(3, {st_mode=S_IFREG|0644, st_size=145136, ...}) = 0
15191 0.000056 [b7efc933] mmap2(NULL, 147584, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0xb7eb2000
15191 0.000036 [b7efc933] mmap2(0xb7ed5000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x22) = 0xb7ed5000
15191 0.000046 [b7efc67d] close(3) = 0
15191 0.000031 [b7efc781] access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
15191 0.000041 [b7efc644] open("/lib/tls/i686/cmov/libnsl.so.1", O_RDONLY) = 3
15191 0.000048 [b7efc6c4] read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0p5\0\000"..., 512) = 512
15191 0.000047 [b7efc60e] fstat64(3, {st_mode=S_IFREG|0644, st_size=76548, ...}) = 0
15191 0.000056 [b7efc933] mmap2(NULL, 87808, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0xb7e9c000
15191 0.000034 [b7efc933] mmap2(0xb7eae000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x11) = 0xb7eae000
15191 0.000043 [b7efc933] mmap2(0xb7eb0000, 5888, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0xb7eb0000
15191 0.000038 [b7efc67d] close(3) = 0
15191 0.000031 [b7efc781] access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
15191 0.000043 [b7efc644] open("/lib/tls/i686/cmov/librt.so.1", O_RDONLY) = 3
15191 0.000046 [b7efc6c4] read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0000\36\0"..., 512) = 512
15191 0.000048 [b7efc60e] fstat64(3, {st_mode=S_IFREG|0644, st_size=30612, ...}) = 0
15191 0.000056 [b7efc933] mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb7e9b000
15191 0.000037 [b7efc933] mmap2(NULL, 33384, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0xb7e92000
15191 0.000034 [b7efc933] mmap2(0xb7e99000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x6) = 0xb7e99000
15191 0.000047 [b7efc67d] close(3) = 0
15191 0.000031 [b7efc781] access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
15191 0.000041 [b7efc644] open("/lib/tls/i686/cmov/libpthread.so.0", O_RDONLY) = 3
15191 0.000047 [b7efc6c4] read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0\240H\0"..., 512) = 512
15191 0.000047 [b7efc60e] fstat64(3, {st_mode=S_IFREG|0755, st_size=89370, ...}) = 0
15191 0.000056 [b7efc933] mmap2(NULL, 70104, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0xb7e80000
15191 0.000048 [b7efc933] mmap2(0xb7e8e000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0xe) = 0xb7e8e000
15191 0.000043 [b7efc933] mmap2(0xb7e90000, 4568, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0xb7e90000
15191 0.000039 [b7efc67d] close(3) = 0
15191 0.000031 [b7efc781] access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
15191 0.000053 [b7efc644] open("/usr/lib/i686/cmov/libssl.so.0.9.8", O_RDONLY) = 3
15191 0.000045 [b7efc6c4] read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0\220\255"..., 512) = 512
15191 0.000050 [b7efc60e] fstat64(3, {st_mode=S_IFREG|0644, st_size=253120, ...}) = 0
15191 0.000056 [b7efc933] mmap2(NULL, 256084, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0xb7e41000
15191 0.000034 [b7efc933] mmap2(0xb7e7c000, 16384, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x3a) = 0xb7e7c000
15191 0.000046 [b7efc67d] close(3) = 0
15191 0.000032 [b7efc781] access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
15191 0.000045 [b7efc644] open("/usr/lib/i686/cmov/libcrypto.so.0.9.8", O_RDONLY) = 3
15191 0.000045 [b7efc6c4] read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0\300Y\3"..., 512) = 512
15191 0.000047 [b7efc60e] fstat64(3, {st_mode=S_IFREG|0644, st_size=1270520, ...}) = 0
15191 0.000056 [b7efc933] mmap2(NULL, 1282904, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0xb7d07000
15191 0.000035 [b7efc933] mmap2(0xb7e29000, 81920, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x122) = 0xb7e29000
15191 0.000053 [b7efc933] mmap2(0xb7e3d000, 13144, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0xb7e3d000
15191 0.000040 [b7efc67d] close(3) = 0
15191 0.000031 [b7efc781] access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
15191 0.000043 [b7efc644] open("/lib/tls/i686/cmov/libc.so.6", O_RDONLY) = 3
15191 0.000043 [b7efc6c4] read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0\240O\1"..., 512) = 512
15191 0.000045 [b7efc60e] fstat64(3, {st_mode=S_IFREG|0644, st_size=1241392, ...}) = 0
15191 0.000057 [b7efc933] mmap2(NULL, 1247388, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0xb7bd6000
15191 0.000034 [b7efc933] mmap2(0xb7cfd000, 28672, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x127) = 0xb7cfd000
15191 0.000043 [b7efc933] mmap2(0xb7d04000, 10396, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0xb7d04000
15191 0.000038 [b7efc67d] close(3) = 0
15191 0.000041 [b7efc781] access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
15191 0.000041 [b7efc644] open("/lib/tls/i686/cmov/libdl.so.2", O_RDONLY) = 3
15191 0.000045 [b7efc6c4] read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0\20\f\0"..., 512) = 512
15191 0.000046 [b7efc60e] fstat64(3, {st_mode=S_IFREG|0644, st_size=9592, ...}) = 0
15191 0.000056 [b7efc933] mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb7bd5000
15191 0.000039 [b7efc933] mmap2(NULL, 12404, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0xb7bd1000
15191 0.000034 [b7efc933] mmap2(0xb7bd3000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x1) = 0xb7bd3000
15191 0.000045 [b7efc67d] close(3) = 0
15191 0.000031 [b7efc781] access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
15191 0.000041 [b7efc644] open("/usr/lib/libz.so.1", O_RDONLY) = 3
15191 0.000044 [b7efc6c4] read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0\340\26"..., 512) = 512
15191 0.000047 [b7efc60e] fstat64(3, {st_mode=S_IFREG|0644, st_size=78500, ...}) = 0
15191 0.000056 [b7efc933] mmap2(NULL, 81456, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0xb7bbd000
15191 0.000035 [b7efc933] mmap2(0xb7bd0000, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x12) = 0xb7bd0000
15191 0.000040 [b7efc67d] close(3) = 0
15191 0.000071 [b7efc933] mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb7bbc000
15191 0.000278 [b7efc9b4] mprotect(0xb7cfd000, 20480, PROT_READ) = 0
15191 0.000280 [b7eeec11] set_thread_area({entry_number:-1 -> 6, base_addr:0xb7bbc6c0, limit:1048575, seg_32bit:1, contents:0, read_exec_only:0, limit_in_pages:1, seg_not_present:0, useable:1}) = 0
15191 0.000057 [b7efc971] munmap(0xb7ed7000, 71336) = 0
15191 0.000038 [b7eeb424] set_tid_address(0xb7bbc708) = 15191
15191 0.000039 [b7eeb424] rt_sigaction(SIGRTMIN, {0xb7e844c0, [], SA_SIGINFO}, NULL, 8) = 0
15191 0.000046 [b7eeb424] rt_sigaction(SIGRT_1, {0xb7e84420, [], SA_RESTART|SA_SIGINFO}, NULL, 8) = 0
15191 0.000038 [b7eeb424] rt_sigprocmask(SIG_UNBLOCK, [RTMIN RT_1], NULL, 8) = 0
15191 0.000039 [b7eeb424] getrlimit(RLIMIT_STACK, {rlim_cur=8192*1024, rlim_max=RLIM_INFINITY}) = 0
15191 0.000058 [b7eeb424] uname({sys="Linux", node="asus-laptop", ...}) = 0
15191 0.000238 [b7eeb424] gettimeofday({1215118640, 424400}, NULL) = 0
15191 0.000036 [b7eeb424] gettimeofday({1215118640, 424433}, NULL) = 0
15191 0.000069 [b7eeb424] brk(0) = 0x8080000
15191 0.000027 [b7eeb424] brk(0x80a1000) = 0x80a1000
15191 0.000042 [b7eeb424] open("/etc/localtime", O_RDONLY) = 3
15191 0.000043 [b7eeb424] fstat64(3, {st_mode=S_IFREG|0644, st_size=2652, ...}) = 0
15191 0.000061 [b7eeb424] fstat64(3, {st_mode=S_IFREG|0644, st_size=2652, ...}) = 0
15191 0.000057 [b7eeb424] mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb7ee8000
15191 0.000033 [b7eeb424] read(3, "TZif2\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\6\0\0\0\6\0\0"..., 4096) = 2652
15191 0.000066 [b7eeb424] close(3) = 0
15191 0.000028 [b7eeb424] munmap(0xb7ee8000, 4096) = 0
15191 0.000049 [b7eeb424] fstat64(1, {st_mode=S_IFCHR|0620, st_rdev=makedev(136, 1), ...}) = 0
15191 0.000057 [b7eeb424] mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb7ee8000
15191 0.000036 [b7eeb424] write(1, " 22:57:20.424 os_core_unix.c pjl"..., 71) = 71
15191 0.000162 [b7eeb424] uname({sys="Linux", node="asus-laptop", ...}) = 0
15191 0.000144 [b7eeb424] mmap2(NULL, 266240, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb7b7b000
15191 0.000039 [b7eeb424] mmap2(NULL, 266240, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb7b3a000
15191 0.000344 [b7eeb424] gettimeofday({1215118640, 425691}, NULL) = 0
15191 0.000038 [b7eeb424] write(1, " 22:57:20.425 pjlib sel"..., 69) = 69
15191 0.000048 [b7eeb424] gettimeofday({1215118640, 425777}, NULL) = 0
15191 0.000037 [b7eeb424] write(1, " 22:57:20.425 sip_endpoint.c Mod"..., 63) = 63
15191 0.000044 [b7eeb424] futex(0x80806d8, FUTEX_WAKE, 1) = 0
15191 0.000114 [b7eeb424] gettimeofday({1215118640, 425972}, NULL) = 0
15191 0.000037 [b7eeb424] write(1, " 22:57:20.425 sip_endpoint.c Mod"..., 63) = 63
15191 0.000042 [b7eeb424] futex(0x80806d8, FUTEX_WAKE, 1) = 0
15191 0.000031 [b7eeb424] gettimeofday({1215118640, 426080}, NULL) = 0
15191 0.000034 [b7eeb424] write(1, " 22:57:20.426 sip_endpoint.c Mod"..., 67) = 67
15191 0.000041 [b7eeb424] futex(0x80806d8, FUTEX_WAKE, 1) = 0
15191 0.000037 [b7eeb424] socket(PF_INET, SOCK_DGRAM, IPPROTO_IP) = 3
15191 0.000049 [b7eeb424] bind(3, {sa_family=AF_INET, sin_port=htons(5060), sin_addr=inet_addr("0.0.0.0")}, 16) = 0
15191 0.000053 [b7eeb424] getsockname(3, {sa_family=AF_INET, sin_port=htons(5060), sin_addr=inet_addr("0.0.0.0")}, [16]) = 0
15191 0.000094 [b7eeb424] gettimeofday({1215118640, 426390}, NULL) = 0
15191 0.000037 [b7eeb424] open("/etc/resolv.conf", O_RDONLY) = 4
15191 0.000047 [b7eeb424] fstat64(4, {st_mode=S_IFREG|0644, st_size=46, ...}) = 0
15191 0.000057 [b7eeb424] mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb7ee7000
15191 0.000032 [b7eeb424] read(4, "nameserver 85.37.17.47\nnameserve"..., 4096) = 46
15191 0.000056 [b7eeb424] read(4, "", 4096) = 0
15191 0.000029 [b7eeb424] close(4) = 0
15191 0.000028 [b7eeb424] munmap(0xb7ee7000, 4096) = 0
15191 0.000032 [b7eeb424] uname({sys="Linux", node="asus-laptop", ...}) = 0
15191 0.000131 [b7eeb424] socket(PF_FILE, SOCK_STREAM, 0) = 4
15191 0.000034 [b7eeb424] fcntl64(4, F_GETFL) = 0x2 (flags O_RDWR)
15191 0.000047 [b7eeb424] fcntl64(4, F_SETFL, O_RDWR|O_NONBLOCK) = 0
15191 0.000033 [b7eeb424] connect(4, {sa_family=AF_FILE, path="/var/run/nscd/socket"}, 110) = -1 ENOENT (No such file or directory)
15191 0.000069 [b7eeb424] close(4) = 0
15191 0.000035 [b7eeb424] socket(PF_FILE, SOCK_STREAM, 0) = 4
15191 0.000031 [b7eeb424] fcntl64(4, F_GETFL) = 0x2 (flags O_RDWR)
15191 0.000029 [b7eeb424] fcntl64(4, F_SETFL, O_RDWR|O_NONBLOCK) = 0
15191 0.000031 [b7eeb424] connect(4, {sa_family=AF_FILE, path="/var/run/nscd/socket"}, 110) = -1 ENOENT (No such file or directory)
15191 0.000061 [b7eeb424] close(4) = 0
15191 0.000033 [b7eeb424] open("/etc/nsswitch.conf", O_RDONLY) = 4
15191 0.000045 [b7eeb424] fstat64(4, {st_mode=S_IFREG|0644, st_size=475, ...}) = 0
15191 0.000057 [b7eeb424] mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb7ee7000
15191 0.000031 [b7eeb424] read(4, "# /etc/nsswitch.conf\n#\n# Example"..., 4096) = 475
15191 0.000062 [b7eeb424] read(4, "", 4096) = 0
15191 0.000028 [b7eeb424] close(4) = 0
15191 0.000028 [b7eeb424] munmap(0xb7ee7000, 4096) = 0
15191 0.000046 [b7efc644] open("/etc/ld.so.cache", O_RDONLY) = 4
15191 0.000039 [b7efc60e] fstat64(4, {st_mode=S_IFREG|0644, st_size=71336, ...}) = 0
15191 0.000056 [b7efc933] mmap2(NULL, 71336, PROT_READ, MAP_PRIVATE, 4, 0) = 0xb7b28000
15191 0.000034 [b7efc67d] close(4) = 0
15191 0.000030 [b7efc781] access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
15191 0.000051 [b7efc644] open("/lib/tls/i686/cmov/libnss_files.so.2", O_RDONLY) = 4
15191 0.000051 [b7efc6c4] read(4, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0\200\33"..., 512) = 512
15191 0.000050 [b7efc60e] fstat64(4, {st_mode=S_IFREG|0644, st_size=38372, ...}) = 0
15191 0.000057 [b7efc933] mmap2(NULL, 41620, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 4, 0) = 0xb7edd000
15191 0.000036 [b7efc933] mmap2(0xb7ee6000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 4, 0x8) = 0xb7ee6000
15191 0.000048 [b7efc67d] close(4) = 0
15191 0.000058 [b7efc971] munmap(0xb7b28000, 71336) = 0
15191 0.000045 [b7eeb424] open("/etc/host.conf", O_RDONLY) = 4
15191 0.000051 [b7eeb424] fstat64(4, {st_mode=S_IFREG|0644, st_size=9, ...}) = 0
15191 0.000057 [b7eeb424] mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb7edc000
15191 0.000032 [b7eeb424] read(4, "multi on\n", 4096) = 9
15191 0.000046 [b7eeb424] read(4, "", 4096) = 0
15191 0.000028 [b7eeb424] close(4) = 0
15191 0.000027 [b7eeb424] munmap(0xb7edc000, 4096) = 0
15191 0.000035 [b7eeb424] futex(0xb7d05ac0, FUTEX_WAKE, 2147483647) = 0
15191 0.000037 [b7eeb424] open("/etc/hosts", O_RDONLY) = 4
15191 0.000043 [b7eeb424] fcntl64(4, F_GETFD) = 0
15191 0.000028 [b7eeb424] fcntl64(4, F_SETFD, FD_CLOEXEC) = 0
15191 0.000032 [b7eeb424] fstat64(4, {st_mode=S_IFREG|0644, st_size=579, ...}) = 0
15191 0.000055 [b7eeb424] mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb7edc000
15191 0.000032 [b7eeb424] read(4, "127.0.0.1\tlocalhost asus-laptop\n"..., 4096) = 579
15191 0.000065 [b7eeb424] read(4, "", 4096) = 0
15191 0.000032 [b7eeb424] close(4) = 0
15191 0.000027 [b7eeb424] munmap(0xb7edc000, 4096) = 0
15191 0.000038 [b7eeb424] socket(PF_INET, SOCK_DGRAM, IPPROTO_IP) = 4
15191 0.000036 [b7eeb424] connect(4, {sa_family=AF_INET, sin_port=htons(0), sin_addr=inet_addr("127.0.0.1")}, 16) = 0
15191 0.000046 [b7eeb424] getsockname(4, {sa_family=AF_INET, sin_port=htons(51870), sin_addr=inet_addr("127.0.0.1")}, [16]) = 0
15191 0.000062 [b7eeb424] close(4) = 0
15191 0.000050 [b7eeb424] socket(PF_INET, SOCK_DGRAM, IPPROTO_IP) = 4
15191 0.000042 [b7eeb424] connect(4, {sa_family=AF_INET, sin_port=htons(53), sin_addr=inet_addr("1.1.1.1")}, 28) = 0
15191 0.000043 [b7eeb424] getsockname(4, {sa_family=AF_INET, sin_port=htons(34721), sin_addr=inet_addr("<my_public_ip_address>")}, [16]) = 0
15191 0.000077 [b7eeb424] close(4) = 0
15191 0.000038 [b7eeb424] futex(0xb7d05d08, FUTEX_WAKE, 2147483647) = 0
15191 0.000043 [b7eeb424] getsockname(3, {sa_family=AF_INET, sin_port=htons(5060), sin_addr=inet_addr("0.0.0.0")}, [16]) = 0
15191 0.000074 [b7eeb424] setsockopt(3, SOL_SOCKET, SO_RCVBUF, [25165824], 4) = 0
15191 0.000036 [b7eeb424] setsockopt(3, SOL_SOCKET, SO_SNDBUF, [25165824], 4) = 0
15191 0.000040 [b7eeb424] gettimeofday({1215118640, 429345}, NULL) = 0
15191 0.000039 [b7eeb424] getsockopt(3, SOL_SOCKET, SO_TYPE, [2], [4]) = 0
15191 0.000036 [b7eeb424] ioctl(3, FIONBIO, [1]) = 0
15191 0.000053 [b7eeb424] gettimeofday({1215118640, 429473}, NULL) = 0
15191 0.000039 [b7eeb424] write(1, " 22:57:20.429 udp0x8097428 SIP"..., 95) = 95
15191 0.000051 [b7eeb424] gettimeofday({1215118640, 429563}, NULL) = 0
15191 0.000036 [b7eeb424] write(1, " 22:57:20.429 sip_endpoint.c Mod"..., 64) = 64
15191 0.000042 [b7eeb424] futex(0x80806d8, FUTEX_WAKE, 1) = 0
15191 0.000042 [b7eeb424] open("/etc/hosts", O_RDONLY) = 4
15191 0.000040 [b7eeb424] fcntl64(4, F_GETFD) = 0
15191 0.000027 [b7eeb424] fcntl64(4, F_SETFD, FD_CLOEXEC) = 0
15191 0.000029 [b7eeb424] fstat64(4, {st_mode=S_IFREG|0644, st_size=579, ...}) = 0
15191 0.000055 [b7eeb424] mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb7edc000
15191 0.000034 [b7eeb424] read(4, "127.0.0.1\tlocalhost asus-laptop\n"..., 4096) = 579
15191 0.000051 [b7eeb424] read(4, "", 4096) = 0
15191 0.000029 [b7eeb424] close(4) = 0
15191 0.000028 [b7eeb424] munmap(0xb7edc000, 4096) = 0
15191 0.000035 [b7eeb424] socket(PF_INET, SOCK_DGRAM, IPPROTO_IP) = 4
15191 0.000035 [b7eeb424] connect(4, {sa_family=AF_INET, sin_port=htons(0), sin_addr=inet_addr("127.0.0.1")}, 16) = 0
15191 0.000039 [b7eeb424] getsockname(4, {sa_family=AF_INET, sin_port=htons(33334), sin_addr=inet_addr("127.0.0.1")}, [16]) = 0
15191 0.000062 [b7eeb424] close(4) = 0
15191 0.000038 [b7eeb424] socket(PF_INET, SOCK_DGRAM, IPPROTO_IP) = 4
15191 0.000036 [b7eeb424] connect(4, {sa_family=AF_INET, sin_port=htons(53), sin_addr=inet_addr("1.1.1.1")}, 28) = 0
15191 0.000042 [b7eeb424] getsockname(4, {sa_family=AF_INET, sin_port=htons(40791), sin_addr=inet_addr("<my_public_ip_address>")}, [16]) = 0
15191 0.000062 [b7eeb424] close(4) = 0
15191 0.000042 [b7eeb424] socket(PF_NETLINK, SOCK_RAW, 0) = 4
15191 0.000035 [b7eeb424] bind(4, {sa_family=AF_NETLINK, pid=0, groups=00000000}, 12) = 0
15191 0.000038 [b7eeb424] getsockname(4, {sa_family=AF_NETLINK, pid=15191, groups=00000000}, [12]) = 0
15191 0.000060 [b7eeb424] time(NULL) = 1215118640
15191 0.000032 [b7eeb424] sendto(4, "\24\0\0\0\22\0\1\0030=mH\0\0\0\0\0!\312\267", 20, 0, {sa_family=AF_NETLINK, pid=0, groups=00000000}, 12) = 20
15191 0.000072 [b7eeb424] recvmsg(4, {msg_name(12)={sa_family=AF_NETLINK, pid=0, groups=00000000}, msg_iov(1)=[{"\354\0\0\0\20\0\2\0000=mHW;\0\0\0\0\4\3\1\0\0\0I\0\1\0"..., 4096}], msg_controllen=0, msg_flags=0}, 0) = 1188
15191 0.000073 [b7eeb424] recvmsg(4, {msg_name(12)={sa_family=AF_NETLINK, pid=0, groups=00000000}, msg_iov(1)=[{"\24\0\0\0\3\0\2\0000=mHW;\0\0\0\0\0\0\1\0\0\0I\0\1\0\0"..., 4096}], msg_controllen=0, msg_flags=0}, 0) = 20
15191 0.000066 [b7eeb424] sendto(4, "\24\0\0\0\26\0\1\0031=mH\0\0\0\0\0!\312\267", 20, 0, {sa_family=AF_NETLINK, pid=0, groups=00000000}, 12) = 20
15191 0.000055 [b7eeb424] recvmsg(4, {msg_name(12)={sa_family=AF_NETLINK, pid=0, groups=00000000}, msg_iov(1)=[{"0\0\0\0\24\0\2\0001=mHW;\0\0\2\10\200\376\1\0\0\0\10\0"..., 4096}], msg_controllen=0, msg_flags=0}, 0) = 160
15191 0.000067 [b7eeb424] recvmsg(4, {msg_name(12)={sa_family=AF_NETLINK, pid=0, groups=00000000}, msg_iov(1)=[{"\24\0\0\0\3\0\2\0001=mHW;\0\0\0\0\0\0\1\0\0\0\10\0\1\0"..., 4096}], msg_controllen=0, msg_flags=0}, 0) = 20
15191 0.000074 [b7eeb424] close(4) = 0
15191 0.000050 [0806e834] --- SIGSEGV (Segmentation fault) @ 0 (0) ---
15191 0.000150 [????????] +++ killed by SIGSEGV +++

When call to that function is disabled the program works fine.

=== STRACE LOG ('strace -rif -o strace.log ./stateful_proxy-i686-pc-linux-gnu') ===

12932      0.000000 [b7f9b424] execve("./stateful_proxy-i686-pc-linux-gnu", ["./stateful_proxy-i686-pc-linux-g"...], [/* 35 vars */]) = 0
12932      0.017510 [b7fcd9ed] uname({sys="Linux", node="asus-laptop", ...}) = 0
12932      0.000211 [b7fccedb] brk(0)   = 0x8080000
12932      0.000046 [b7fcd781] access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
12932      0.000060 [b7fcd933] mmap2(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb7fba000
12932      0.000041 [b7fcd781] access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory)
12932      0.000054 [b7fcd644] open("/etc/ld.so.cache", O_RDONLY) = 3
12932      0.000040 [b7fcd60e] fstat64(3, {st_mode=S_IFREG|0644, st_size=71336, ...}) = 0
12932      0.000075 [b7fcd933] mmap2(NULL, 71336, PROT_READ, MAP_PRIVATE, 3, 0) = 0xb7fa8000
12932      0.000032 [b7fcd67d] close(3) = 0
12932      0.000031 [b7fcd781] access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
12932      0.000050 [b7fcd644] open("/lib/tls/i686/cmov/libm.so.6", O_RDONLY) = 3
12932      0.000057 [b7fcd6c4] read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0`3\0\000"..., 512) = 512
12932      0.000054 [b7fcd60e] fstat64(3, {st_mode=S_IFREG|0644, st_size=145136, ...}) = 0
12932      0.000063 [b7fcd933] mmap2(NULL, 147584, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0xb7f83000
12932      0.000037 [b7fcd933] mmap2(0xb7fa6000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x22) = 0xb7fa6000
12932      0.000051 [b7fcd67d] close(3) = 0
12932      0.000033 [b7fcd781] access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
12932      0.000042 [b7fcd644] open("/lib/tls/i686/cmov/libnsl.so.1", O_RDONLY) = 3
12932      0.000048 [b7fcd6c4] read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0p5\0\000"..., 512) = 512
12932      0.000051 [b7fcd60e] fstat64(3, {st_mode=S_IFREG|0644, st_size=76548, ...}) = 0
12932      0.000064 [b7fcd933] mmap2(NULL, 87808, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0xb7f6d000
12932      0.000035 [b7fcd933] mmap2(0xb7f7f000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x11) = 0xb7f7f000
12932      0.000046 [b7fcd933] mmap2(0xb7f81000, 5888, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0xb7f81000
12932      0.000042 [b7fcd67d] close(3) = 0
12932      0.000032 [b7fcd781] access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
12932      0.000044 [b7fcd644] open("/lib/tls/i686/cmov/librt.so.1", O_RDONLY) = 3
12932      0.000047 [b7fcd6c4] read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0000\36\0"..., 512) = 512
12932      0.000052 [b7fcd60e] fstat64(3, {st_mode=S_IFREG|0644, st_size=30612, ...}) = 0
12932      0.000063 [b7fcd933] mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb7f6c000
12932      0.000040 [b7fcd933] mmap2(NULL, 33384, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0xb7f63000
12932      0.000035 [b7fcd933] mmap2(0xb7f6a000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x6) = 0xb7f6a000
12932      0.000049 [b7fcd67d] close(3) = 0
12932      0.000033 [b7fcd781] access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
12932      0.000041 [b7fcd644] open("/lib/tls/i686/cmov/libpthread.so.0", O_RDONLY) = 3
12932      0.000049 [b7fcd6c4] read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0\240H\0"..., 512) = 512
12932      0.000051 [b7fcd60e] fstat64(3, {st_mode=S_IFREG|0755, st_size=89370, ...}) = 0
12932      0.000063 [b7fcd933] mmap2(NULL, 70104, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0xb7f51000
12932      0.000036 [b7fcd933] mmap2(0xb7f5f000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0xe) = 0xb7f5f000
12932      0.000047 [b7fcd933] mmap2(0xb7f61000, 4568, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0xb7f61000
12932      0.000042 [b7fcd67d] close(3) = 0
12932      0.000033 [b7fcd781] access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
12932      0.000054 [b7fcd644] open("/usr/lib/i686/cmov/libssl.so.0.9.8", O_RDONLY) = 3
12932      0.000047 [b7fcd6c4] read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0\220\255"..., 512) = 512
12932      0.009197 [b7fcd60e] fstat64(3, {st_mode=S_IFREG|0644, st_size=253120, ...}) = 0
12932      0.000106 [b7fcd933] mmap2(NULL, 256084, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0xb7f12000
12932      0.000059 [b7fcd933] mmap2(0xb7f4d000, 16384, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x3a) = 0xb7f4d000
12932      0.000067 [b7fcd67d] close(3) = 0
12932      0.000034 [b7fcd781] access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
12932      0.000047 [b7fcd644] open("/usr/lib/i686/cmov/libcrypto.so.0.9.8", O_RDONLY) = 3
12932      0.000047 [b7fcd6c4] read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0\300Y\3"..., 512) = 512
12932      0.000052 [b7fcd60e] fstat64(3, {st_mode=S_IFREG|0644, st_size=1270520, ...}) = 0
12932      0.000063 [b7fcd933] mmap2(NULL, 1282904, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0xb7dd8000
12932      0.000037 [b7fcd933] mmap2(0xb7efa000, 81920, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x122) = 0xb7efa000
12932      0.000047 [b7fcd933] mmap2(0xb7f0e000, 13144, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0xb7f0e000
12932      0.000041 [b7fcd67d] close(3) = 0
12932      0.000033 [b7fcd781] access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
12932      0.000044 [b7fcd644] open("/lib/tls/i686/cmov/libc.so.6", O_RDONLY) = 3
12932      0.000045 [b7fcd6c4] read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0\240O\1"..., 512) = 512
12932      0.000049 [b7fcd60e] fstat64(3, {st_mode=S_IFREG|0644, st_size=1241392, ...}) = 0
12932      0.000066 [b7fcd933] mmap2(NULL, 1247388, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0xb7ca7000
12932      0.000036 [b7fcd933] mmap2(0xb7dce000, 28672, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x127) = 0xb7dce000
12932      0.000044 [b7fcd933] mmap2(0xb7dd5000, 10396, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0xb7dd5000
12932      0.000041 [b7fcd67d] close(3) = 0
12932      0.000041 [b7fcd781] access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
12932      0.000042 [b7fcd644] open("/lib/tls/i686/cmov/libdl.so.2", O_RDONLY) = 3
12932      0.000116 [b7fcd6c4] read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0\20\f\0"..., 512) = 512
12932      0.000052 [b7fcd60e] fstat64(3, {st_mode=S_IFREG|0644, st_size=9592, ...}) = 0
12932      0.000063 [b7fcd933] mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb7ca6000
12932      0.000040 [b7fcd933] mmap2(NULL, 12404, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0xb7ca2000
12932      0.000036 [b7fcd933] mmap2(0xb7ca4000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x1) = 0xb7ca4000
12932      0.000048 [b7fcd67d] close(3) = 0
12932      0.000048 [b7fcd781] access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
12932      0.000052 [b7fcd644] open("/usr/lib/libz.so.1", O_RDONLY) = 3
12932      0.036021 [b7fcd6c4] read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0\340\26"..., 512) = 512
12932      0.000087 [b7fcd60e] fstat64(3, {st_mode=S_IFREG|0644, st_size=78500, ...}) = 0
12932      0.000106 [b7fcd933] mmap2(NULL, 81456, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0xb7c8e000
12932      0.000065 [b7fcd933] mmap2(0xb7ca1000, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x12) = 0xb7ca1000
12932      0.000043 [b7fcd67d] close(3) = 0
12932      0.000074 [b7fcd933] mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb7c8d000
12932      0.000290 [b7fcd9b4] mprotect(0xb7dce000, 20480, PROT_READ) = 0
12932      0.000303 [b7fbfc11] set_thread_area({entry_number:-1 -> 6, base_addr:0xb7c8d6c0, limit:1048575, seg_32bit:1, contents:0, read_exec_only:0, limit_in_pages:1, seg_not_present:0, useable:1}) = 0
12932      0.000063 [b7fcd971] munmap(0xb7fa8000, 71336) = 0
12932      0.000039 [b7fbc424] set_tid_address(0xb7c8d708) = 12932
12932      0.000041 [b7fbc424] rt_sigaction(SIGRTMIN, {0xb7f554c0, [], SA_SIGINFO}, NULL, 8) = 0
12932      0.000049 [b7fbc424] rt_sigaction(SIGRT_1, {0xb7f55420, [], SA_RESTART|SA_SIGINFO}, NULL, 8) = 0
12932      0.000041 [b7fbc424] rt_sigprocmask(SIG_UNBLOCK, [RTMIN RT_1], NULL, 8) = 0
12932      0.000041 [b7fbc424] getrlimit(RLIMIT_STACK, {rlim_cur=8192*1024, rlim_max=RLIM_INFINITY}) = 0
12932      0.000061 [b7fbc424] uname({sys="Linux", node="asus-laptop", ...}) = 0
12932      0.002334 [b7fbc424] gettimeofday({1215165772, 445126}, NULL) = 0
12932      0.000064 [b7fbc424] gettimeofday({1215165772, 445183}, NULL) = 0
12932      0.000118 [b7fbc424] brk(0)   = 0x8080000
12932      0.000048 [b7fbc424] brk(0x80a1000) = 0x80a1000
12932      0.000077 [b7fbc424] open("/etc/localtime", O_RDONLY) = 3
12932      0.000046 [b7fbc424] fstat64(3, {st_mode=S_IFREG|0644, st_size=2652, ...}) = 0
12932      0.000068 [b7fbc424] fstat64(3, {st_mode=S_IFREG|0644, st_size=2652, ...}) = 0
12932      0.000064 [b7fbc424] mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb7fb9000
12932      0.000035 [b7fbc424] read(3, "TZif2\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\6\0\0\0\6\0\0"..., 4096) = 2652
12932      0.000062 [b7fbc424] close(3) = 0
12932      0.000030 [b7fbc424] munmap(0xb7fb9000, 4096) = 0
12932      0.000052 [b7fbc424] fstat64(1, {st_mode=S_IFCHR|0620, st_rdev=makedev(136, 0), ...}) = 0
12932      0.000065 [b7fbc424] mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb7fb9000
12932      0.000038 [b7fbc424] write(1, " 12:02:52.445 os_core_unix.c pjl"..., 71) = 71
12932      0.000754 [b7fbc424] uname({sys="Linux", node="asus-laptop", ...}) = 0
12932      0.000240 [b7fbc424] mmap2(NULL, 266240, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb7c4c000
12932      0.000040 [b7fbc424] mmap2(NULL, 266240, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb7c0b000
12932      0.000350 [b7fbc424] gettimeofday({1215165772, 447265}, NULL) = 0
12932      0.000040 [b7fbc424] write(1, " 12:02:52.447          pjlib sel"..., 69) = 69
12932      0.000063 [b7fbc424] gettimeofday({1215165772, 447367}, NULL) = 0
12932      0.000038 [b7fbc424] write(1, " 12:02:52.447 sip_endpoint.c Mod"..., 63) = 63
12932      0.000047 [b7fbc424] futex(0x80806d8, FUTEX_WAKE, 1) = 0
12932      0.000116 [b7fbc424] gettimeofday({1215165772, 447584}, NULL) = 0
12932      0.000053 [b7fbc424] write(1, " 12:02:52.447 sip_endpoint.c Mod"..., 63) = 63
12932      0.000045 [b7fbc424] futex(0x80806d8, FUTEX_WAKE, 1) = 0
12932      0.000032 [b7fbc424] gettimeofday({1215165772, 447698}, NULL) = 0
12932      0.000037 [b7fbc424] write(1, " 12:02:52.447 sip_endpoint.c Mod"..., 67) = 67
12932      0.000044 [b7fbc424] futex(0x80806d8, FUTEX_WAKE, 1) = 0
12932      0.000040 [b7fbc424] socket(PF_INET, SOCK_DGRAM, IPPROTO_IP) = 3
12932      0.000051 [b7fbc424] bind(3, {sa_family=AF_INET, sin_port=htons(5060), sin_addr=inet_addr("0.0.0.0")}, 16) = 0
12932      0.000057 [b7fbc424] getsockname(3, {sa_family=AF_INET, sin_port=htons(5060), sin_addr=inet_addr("0.0.0.0")}, [16]) = 0
12932      0.000102 [b7fbc424] gettimeofday({1215165772, 448030}, NULL) = 0
12932      0.000039 [b7fbc424] open("/etc/resolv.conf", O_RDONLY) = 4
12932      0.000047 [b7fbc424] fstat64(4, {st_mode=S_IFREG|0644, st_size=46, ...}) = 0
12932      0.000064 [b7fbc424] mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb7fb8000
12932      0.000035 [b7fbc424] read(4, "nameserver 85.37.17.47\nnameserve"..., 4096) = 46
12932      0.000060 [b7fbc424] read(4, "", 4096) = 0
12932      0.000031 [b7fbc424] close(4) = 0
12932      0.000029 [b7fbc424] munmap(0xb7fb8000, 4096) = 0
12932      0.000046 [b7fbc424] uname({sys="Linux", node="asus-laptop", ...}) = 0
12932      0.000155 [b7fbc424] socket(PF_FILE, SOCK_STREAM, 0) = 4
12932      0.000039 [b7fbc424] fcntl64(4, F_GETFL) = 0x2 (flags O_RDWR)
12932      0.000051 [b7fbc424] fcntl64(4, F_SETFL, O_RDWR|O_NONBLOCK) = 0
12932      0.000037 [b7fbc424] connect(4, {sa_family=AF_FILE, path="/var/run/nscd/socket"}, 110) = -1 ENOENT (No such file or directory)
12932      0.000085 [b7fbc424] close(4) = 0
12932      0.000038 [b7fbc424] socket(PF_FILE, SOCK_STREAM, 0) = 4
12932      0.000032 [b7fbc424] fcntl64(4, F_GETFL) = 0x2 (flags O_RDWR)
12932      0.000030 [b7fbc424] fcntl64(4, F_SETFL, O_RDWR|O_NONBLOCK) = 0
12932      0.000034 [b7fbc424] connect(4, {sa_family=AF_FILE, path="/var/run/nscd/socket"}, 110) = -1 ENOENT (No such file or directory)
12932      0.000069 [b7fbc424] close(4) = 0
12932      0.000035 [b7fbc424] open("/etc/nsswitch.conf", O_RDONLY) = 4
12932      0.000047 [b7fbc424] fstat64(4, {st_mode=S_IFREG|0644, st_size=475, ...}) = 0
12932      0.000064 [b7fbc424] mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb7fb8000
12932      0.000033 [b7fbc424] read(4, "# /etc/nsswitch.conf\n#\n# Example"..., 4096) = 475
12932      0.000067 [b7fbc424] read(4, "", 4096) = 0
12932      0.000030 [b7fbc424] close(4) = 0
12932      0.000028 [b7fbc424] munmap(0xb7fb8000, 4096) = 0
12932      0.000049 [b7fcd644] open("/etc/ld.so.cache", O_RDONLY) = 4
12932      0.000041 [b7fcd60e] fstat64(4, {st_mode=S_IFREG|0644, st_size=71336, ...}) = 0
12932      0.000062 [b7fcd933] mmap2(NULL, 71336, PROT_READ, MAP_PRIVATE, 4, 0) = 0xb7bf9000
12932      0.000034 [b7fcd67d] close(4) = 0
12932      0.000033 [b7fcd781] access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
12932      0.000052 [b7fcd644] open("/lib/tls/i686/cmov/libnss_files.so.2", O_RDONLY) = 4
12932      0.000054 [b7fcd6c4] read(4, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0\200\33"..., 512) = 512
12932      0.000053 [b7fcd60e] fstat64(4, {st_mode=S_IFREG|0644, st_size=38372, ...}) = 0
12932      0.000065 [b7fcd933] mmap2(NULL, 41620, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 4, 0) = 0xb7fae000
12932      0.000037 [b7fcd933] mmap2(0xb7fb7000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 4, 0x8) = 0xb7fb7000
12932      0.000050 [b7fcd67d] close(4) = 0
12932      0.000064 [b7fcd971] munmap(0xb7bf9000, 71336) = 0
12932      0.000047 [b7fbc424] open("/etc/host.conf", O_RDONLY) = 4
12932      0.014710 [b7fbc424] fstat64(4, {st_mode=S_IFREG|0644, st_size=9, ...}) = 0
12932      0.000106 [b7fbc424] mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb7fad000
12932      0.000056 [b7fbc424] read(4, "multi on\n", 4096) = 9
12932      0.004583 [b7fbc424] read(4, "", 4096) = 0
12932      0.000049 [b7fbc424] close(4) = 0
12932      0.000047 [b7fbc424] munmap(0xb7fad000, 4096) = 0
12932      0.000057 [b7fbc424] futex(0xb7dd6ac0, FUTEX_WAKE, 2147483647) = 0
12932      0.000068 [b7fbc424] open("/etc/hosts", O_RDONLY) = 4
12932      0.000044 [b7fbc424] fcntl64(4, F_GETFD) = 0
12932      0.000029 [b7fbc424] fcntl64(4, F_SETFD, FD_CLOEXEC) = 0
12932      0.000033 [b7fbc424] fstat64(4, {st_mode=S_IFREG|0644, st_size=579, ...}) = 0
12932      0.000063 [b7fbc424] mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb7fad000
12932      0.000034 [b7fbc424] read(4, "127.0.0.1\tlocalhost asus-laptop\n"..., 4096) = 579
12932      0.000068 [b7fbc424] read(4, "", 4096) = 0
12932      0.000033 [b7fbc424] close(4) = 0
12932      0.000029 [b7fbc424] munmap(0xb7fad000, 4096) = 0
12932      0.000039 [b7fbc424] socket(PF_INET, SOCK_DGRAM, IPPROTO_IP) = 4
12932      0.000037 [b7fbc424] connect(4, {sa_family=AF_INET, sin_port=htons(0), sin_addr=inet_addr("127.0.0.1")}, 16) = 0
12932      0.000059 [b7fbc424] getsockname(4, {sa_family=AF_INET, sin_port=htons(54238), sin_addr=inet_addr("127.0.0.1")}, [16]) = 0
12932      0.000072 [b7fbc424] close(4) = 0
12932      0.000051 [b7fbc424] socket(PF_INET, SOCK_DGRAM, IPPROTO_IP) = 4
12932      0.000043 [b7fbc424] connect(4, {sa_family=AF_INET, sin_port=htons(53), sin_addr=inet_addr("1.1.1.1")}, 28) = 0
12932      0.000054 [b7fbc424] getsockname(4, {sa_family=AF_INET, sin_port=htons(50396), sin_addr=inet_addr("<my_public_ip_address>")}, [16]) = 0
12932      0.000087 [b7fbc424] close(4) = 0
12932      0.000038 [b7fbc424] futex(0xb7dd6d08, FUTEX_WAKE, 2147483647) = 0
12932      0.000043 [b7fbc424] getsockname(3, {sa_family=AF_INET, sin_port=htons(5060), sin_addr=inet_addr("0.0.0.0")}, [16]) = 0
12932      0.000084 [b7fbc424] setsockopt(3, SOL_SOCKET, SO_RCVBUF, [25165824], 4) = 0
12932      0.000039 [b7fbc424] setsockopt(3, SOL_SOCKET, SO_SNDBUF, [25165824], 4) = 0
12932      0.000042 [b7fbc424] gettimeofday({1215165772, 470592}, NULL) = 0
12932      0.000043 [b7fbc424] getsockopt(3, SOL_SOCKET, SO_TYPE, [2], [4]) = 0
12932      0.000037 [b7fbc424] ioctl(3, FIONBIO, [1]) = 0
12932      0.000053 [b7fbc424] gettimeofday({1215165772, 470726}, NULL) = 0
12932      0.000040 [b7fbc424] write(1, " 12:02:52.470   udp0x8097428 SIP"..., 96) = 96
12932      0.000054 [b7fbc424] gettimeofday({1215165772, 470820}, NULL) = 0
12932      0.000038 [b7fbc424] write(1, " 12:02:52.470 sip_endpoint.c Mod"..., 64) = 64
12932      0.000045 [b7fbc424] futex(0x80806d8, FUTEX_WAKE, 1) = 0
12932      0.000044 [b7fbc424] open("/etc/hosts", O_RDONLY) = 4
12932      0.000040 [b7fbc424] fcntl64(4, F_GETFD) = 0
12932      0.000030 [b7fbc424] fcntl64(4, F_SETFD, FD_CLOEXEC) = 0
12932      0.000029 [b7fbc424] fstat64(4, {st_mode=S_IFREG|0644, st_size=579, ...}) = 0
12932      0.000063 [b7fbc424] mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb7fad000
12932      0.000034 [b7fbc424] read(4, "127.0.0.1\tlocalhost asus-laptop\n"..., 4096) = 579
12932      0.000056 [b7fbc424] read(4, "", 4096) = 0
12932      0.000030 [b7fbc424] close(4) = 0
12932      0.000029 [b7fbc424] munmap(0xb7fad000, 4096) = 0
12932      0.000038 [b7fbc424] socket(PF_INET, SOCK_DGRAM, IPPROTO_IP) = 4
12932      0.000036 [b7fbc424] connect(4, {sa_family=AF_INET, sin_port=htons(0), sin_addr=inet_addr("127.0.0.1")}, 16) = 0
12932      0.000043 [b7fbc424] getsockname(4, {sa_family=AF_INET, sin_port=htons(46980), sin_addr=inet_addr("127.0.0.1")}, [16]) = 0
12932      0.000072 [b7fbc424] close(4) = 0
12932      0.000040 [b7fbc424] socket(PF_INET, SOCK_DGRAM, IPPROTO_IP) = 4
12932      0.000038 [b7fbc424] connect(4, {sa_family=AF_INET, sin_port=htons(53), sin_addr=inet_addr("1.1.1.1")}, 28) = 0
12932      0.000046 [b7fbc424] getsockname(4, {sa_family=AF_INET, sin_port=htons(37894), sin_addr=inet_addr("<my_public_ip_address>")}, [16]) = 0
12932      0.000071 [b7fbc424] close(4) = 0
12932      0.000033 [b7fbc424] gettimeofday({1215165772, 471674}, NULL) = 0
12932      0.000046 [b7fbc424] write(1, " 12:02:52.471 stateful_proxy Pro"..., 67) = 67
12932      0.000055 [b7fbc424] gettimeofday({1215165772, 471776}, NULL) = 0
12932      0.000037 [b7fbc424] write(1, " 12:02:52.471 stateful_proxy Loc"..., 49) = 49
12932      0.000048 [b7fbc424] gettimeofday({1215165772, 471860}, NULL) = 0
12932      0.000044 [b7fbc424] write(1, " 12:02:52.471 stateful_proxy  82"..., 49) = 49
12932      0.000043 [b7fbc424] gettimeofday({1215165772, 471947}, NULL) = 0
12932      0.000036 [b7fbc424] write(1, " 12:02:52.471 stateful_proxy  12"..., 45) = 45
12932      0.000043 [b7fbc424] gettimeofday({1215165772, 472027}, NULL) = 0
12932      0.000037 [b7fbc424] write(1, " 12:02:52.472 stateful_proxy  as"..., 47) = 47
12932      0.000043 [b7fbc424] gettimeofday({1215165772, 472106}, NULL) = 0
12932      0.000037 [b7fbc424] write(1, " 12:02:52.472 stateful_proxy  lo"..., 45) = 45
12932      0.000044 [b7fbc424] gettimeofday({1215165772, 472188}, NULL) = 0
12932      0.000037 [b7fbc424] write(1, " 12:02:52.472 sip_endpoint.c Mod"..., 68) = 68
12932      0.000045 [b7fbc424] futex(0x80806d8, FUTEX_WAKE, 1) = 0
12932      0.000030 [b7fbc424] gettimeofday({1215165772, 472300}, NULL) = 0
12932      0.000037 [b7fbc424] write(1, " 12:02:52.472 sip_endpoint.c Mod"..., 70) = 70
12932      0.000045 [b7fbc424] futex(0x80806d8, FUTEX_WAKE, 1) = 0
12932      0.000044 [b7fbc424] mmap2(NULL, 8392704, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb740a000
12932      0.000060 [b7fbc424] mprotect(0xb740a000, 4096, PROT_NONE) = 0
12932      0.000039 [b7d72488] clone(child_stack=0xb7c0a4c4, flags=CLONE_VM|CLONE_FS|CLONE_FILES|CLONE_SIGHAND|CLONE_THREAD|CLONE_SYSVSEM|CLONE_SETTLS|CLONE_PARENT_SETTID|CLONE_CHILD_CLEARTID|CLONE_DETACHED, parent_tidptr=0xb7c0abf8, {entry_number:6, base_addr:0xb7c0abb0, limit:1048575, seg_32bit:1, contents:0, read_exec_only:0, limit_in_pages:1, seg_not_present:0, useable:1}, child_tidptr=0xb7c0abf8) = 12933
12933      0.000085 [b7fbc424] select(1024, [3], [], [], {0, 10000} <unfinished ...>
12932      0.000165 [b7fbc424] write(1, "\nMenu:\n  q    quit\n  d    dump s"..., 66) = 66
12932      0.000047 [b7fbc424] write(1, "\n", 1) = 1
12932      0.000037 [b7fbc424] fstat64(0, {st_mode=S_IFCHR|0620, st_rdev=makedev(136, 0), ...}) = 0
12932      0.000065 [b7fbc424] mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb7fad000
12932      0.000035 [b7fbc424] read(0,  <unfinished ...>
12933      0.012107 [b7fbc424] <... select resumed> ) = 0 (Timeout)
12933      0.000038 [b7fbc424] select(1024, [3], [], [], {0, 10000}) = 0 (Timeout)
12933      0.013361 [b7fbc424] select(1024, [3], [], [], {0, 10000}) = 0 (Timeout)
12933      0.013294 [b7fbc424] select(1024, [3], [], [], {0, 10000}) = 0 (Timeout)
12933      0.013333 [b7fbc424] select(1024, [3], [], [], {0, 10000}) = 0 (Timeout)
12933      0.013334 [b7fbc424] select(1024, [3], [], [], {0, 10000}) = 0 (Timeout)
12933      0.013354 [b7fbc424] select(1024, [3], [], [], {0, 10000}) = 0 (Timeout)
12933      0.013323 [b7fbc424] select(1024, [3], [], [], {0, 10000}) = 0 (Timeout)
12933      0.013323 [b7fbc424] select(1024, [3], [], [], {0, 10000}) = 0 (Timeout)
12933      0.013334 [b7fbc424] select(1024, [3], [], [], {0, 10000}) = 0 (Timeout)
12933      0.013351 [b7fbc424] select(1024, [3], [], [], {0, 10000}) = 0 (Timeout)
12933      0.013315 [b7fbc424] select(1024, [3], [], [], {0, 10000}) = 0 (Timeout)
12933      0.013340 [b7fbc424] select(1024, [3], [], [], {0, 10000}) = 0 (Timeout)
12933      0.013326 [b7fbc424] select(1024, [3], [], [], {0, 10000}) = 0 (Timeout)
12933      0.013354 [b7fbc424] select(1024, [3], [], [], {0, 10000}) = 0 (Timeout)
12933      0.013313 [b7fbc424] select(1024, [3], [], [], {0, 10000}) = 0 (Timeout)
12933      0.013333 [b7fbc424] select(1024, [3], [], [], {0, 10000}) = 0 (Timeout)
12933      0.013344 [b7fbc424] select(1024, [3], [], [], {0, 10000}) = 0 (Timeout)
12933      0.013341 [b7fbc424] select(1024, [3], [], [], {0, 10000}) = 0 (Timeout)
12933      0.013319 [b7fbc424] select(1024, [3], [], [], {0, 10000}) = 0 (Timeout)
12933      0.013330 [b7fbc424] select(1024, [3], [], [], {0, 10000}) = 0 (Timeout)
12933      0.013338 [b7fbc424] select(1024, [3], [], [], {0, 10000}) = 0 (Timeout)
12933      0.013354 [b7fbc424] select(1024, [3], [], [], {0, 10000}) = 0 (Timeout)
12933      0.013308 [b7fbc424] select(1024, [3], [], [], {0, 10000}) = 0 (Timeout)
12933      0.013333 [b7fbc424] select(1024, [3], [], [], {0, 10000}) = 0 (Timeout)
12933      0.013333 [b7fbc424] select(1024, [3], [], [], {0, 10000}) = 0 (Timeout)
12933      0.013383 [b7fbc424] select(1024, [3], [], [], {0, 10000} <unfinished ...>
12932      0.006658 [b7fbc424] <... read resumed> "q\n", 1024) = 2
12932      0.000054 [b7fbc424] futex(0xb7c0abf8, FUTEX_WAIT, 12933, NULL <unfinished ...>
12933      0.006591 [b7fbc424] <... select resumed> ) = 0 (Timeout)
12933      0.000044 [b7f56299] _exit(0) = ?
12932      0.000046 [b7fbc424] <... futex resumed> ) = 0
12932      0.000031 [b7fbc424] gettimeofday({1215165772, 831905}, NULL) = 0
12932      0.000068 [b7fbc424] write(1, " 12:02:52.831 sip_endpoint.c Mod"..., 72) = 72
12932      0.000078 [b7fbc424] futex(0x80806d8, FUTEX_WAKE, 1) = 0
12932      0.000030 [b7fbc424] gettimeofday({1215165772, 832074}, NULL) = 0
12932      0.000039 [b7fbc424] write(1, " 12:02:52.832 sip_endpoint.c Mod"..., 69) = 69
12932      0.000045 [b7fbc424] futex(0x80806d8, FUTEX_WAKE, 1) = 0
12932      0.000029 [b7fbc424] gettimeofday({1215165772, 832187}, NULL) = 0
12932      0.000037 [b7fbc424] write(1, " 12:02:52.832 sip_endpoint.c Mod"..., 70) = 70
12932      0.000070 [b7fbc424] futex(0x80806d8, FUTEX_WAKE, 1) = 0
12932      0.000033 [b7fbc424] gettimeofday({1215165772, 832327}, NULL) = 0
12932      0.000037 [b7fbc424] write(1, " 12:02:52.832 sip_transactio Sto"..., 63) = 63
12932      0.000119 [b7fbc424] gettimeofday({1215165772, 832484}, NULL) = 0
12932      0.000038 [b7fbc424] write(1, " 12:02:52.832 sip_transactio Tra"..., 64) = 64
12932      0.000055 [b7fbc424] gettimeofday({1215165772, 832576}, NULL) = 0
12932      0.000037 [b7fbc424] write(1, " 12:02:52.832 sip_endpoint.c Mod"..., 65) = 65
12932      0.000045 [b7fbc424] futex(0x80806d8, FUTEX_WAKE, 1) = 0
12932      0.000029 [b7fbc424] gettimeofday({1215165772, 832687}, NULL) = 0
12932      0.000037 [b7fbc424] write(1, " 12:02:52.832 sip_endpoint.c Mod"..., 65) = 65
12932      0.000056 [b7fbc424] futex(0x80806d8, FUTEX_WAKE, 1) = 0
12932      0.000029 [b7fbc424] gettimeofday({1215165772, 832810}, NULL) = 0
12932      0.000037 [b7fbc424] write(1, " 12:02:52.832 sip_endpoint.c Mod"..., 66) = 66
12932      0.000045 [b7fbc424] futex(0x80806d8, FUTEX_WAKE, 1) = 0
12932      0.000033 [b7fbc424] close(3) = 0
12932      0.000037 [b7fbc424] gettimeofday({1215165772, 832962}, NULL) = 0
12932      0.000036 [b7fbc424] gettimeofday({1215165772, 832997}, NULL) = 0
12932      0.000038 [b7fbc424] nanosleep({0, 1000000}, NULL) = 0
12932      0.002057 [b7fbc424] munmap(0xb7c4c000, 266240) = 0
12932      0.000038 [b7fbc424] munmap(0xb7c0b000, 266240) = 0
12932      0.000058 [b7fbc424] gettimeofday({1215165772, 835189}, NULL) = 0
12932      0.000039 [b7fbc424] write(1, " 12:02:52.835 sip_endpoint.c End"..., 58) = 58
12932      0.000085 [b7fbc424] munmap(0xb7fb9000, 4096) = 0
12932      0.000033 [b7fbc424] exit_group(0) = ?

What do you suggest me to do? I'm out of ideas, as I'm not a Kernel hacker.

Thank you in advance.
Best regards.

-- 
Filippo Zangheri

GPG key ID: 0x6C1F2F2F