[reSIProcate] problems encountered during running test program testDns
resiprocate-devel,hi!
I encountered a problem of "C++ runtime abort: a pure virtual function
was called" when
running the test program testDns, and this seems to be caused by the program's
termination
before the t->thread(os/ThreadIf.cxx:33) is called. My platform is equator, and
this problem can
also be seen if you use gdb to debug it in x86 pc.
I have added some print sentences to the program.
os/ThreadIf.cxx:33
cerr << "os/ThreadIf.cxx:33" << endl;
os/ThreadIf.cxx:69
cerr << "os/ThreadIf.cxx:69" << endl;
testDns.cxx:65
std::cerr << "testDns.cxx:65" << std::endl;
-------------------------------------------------------------------------------
Direct execution of the program in x86 pc will get the following output :
$ ./testDns
os/ThreadIf.cxx:69
os/ThreadIf.cxx:33
testDns.cxx:65
Starting
-------------------------------------------------------------------------------
Run it in GDB will get:
(gdb) run
Starting program: /home/zuobf/sip/resiprocate/test/bin.debug.Linux.i686/testDns
[New Thread 1076758880 (LWP 7661)]
os/ThreadIf.cxx:69
[New Thread 1085148352 (LWP 7662)]
Starting
os/ThreadIf.cxx:33
pure virtual method called
Program received signal SIGABRT, Aborted.
[Switching to Thread 1085148352 (LWP 7662)]
0xffffe002 in ?? ()
(gdb) bt
#0 0xffffe002 in ?? ()
#1 0x42028a73 in abort () from /lib/tls/libc.so.6
#2 0x401e6b57 in __cxa_call_unexpected () from /usr/lib/libstdc++.so.5
#3 0x401e6ba4 in std::terminate() () from /usr/lib/libstdc++.so.5
#4 0x401e7077 in __cxa_pure_virtual () from /usr/lib/libstdc++.so.5
#5 0x0805f5ce in threadWrapper (threadParm=0xbfffe6f8) at os/ThreadIf.cxx:34
#6 0x401522b6 in start_thread () from /lib/tls/libpthread.so.0
-------------------------------------------------------------------------------
Direct execution in my platform will get:
os/ThreadIf.cxx:69
Starting
os/ThreadIf.cxx:33
C++ runtime abort: a pure virtual function was called
What should i do?
Any help is greatly appreciated.
sincerely,
zuobf
zuobf@xxxxxxxxxxxxxxx
2005-04-20