Hi: A core file is generated by a tomcat server running JNI code. Almost every 9 days it crashes at the same place. The $eip does not point to .text section, but @plt section. The code breaks at writen@plt, so I don't have $ebp+0x4 point to the caller. I don't have clue as to which line caused the crash. Is it a problem related with GCC compiler? It is not a compilation bug. #8 0x6b7209ec in writen () from /export/home/fengd/project/log/k/libhcnetsdk.so ================== Core was generated by `/usr/java/jdk1.5.0_11/jre/bin/java -Djava.util.logging.manager=org.apache.juli.'. Program terminated with signal 6, Aborted. #0 0xffffe410 in __kernel_vsyscall () (gdb) bt #0 0xffffe410 in __kernel_vsyscall () #1 0xb7e0b7d0 in raise () from /lib/libc.so.6 #2 0xb7e0cea3 in abort () from /lib/libc.so.6 #3 0xb7836b35 in os::abort(int) () from /usr/java/jdk1.5.0_11/jre/lib/i386/server/libjvm.so #4 0xb79143f4 in VMError::report_and_die() () from /usr/java/jdk1.5.0_11/jre/lib/i386/server/libjvm.so #5 0xb783b72a in JVM_handle_linux_signal () from /usr/java/jdk1.5.0_11/jre/lib/i386/server/libjvm.so #6 0xb7838ba4 in signalHandler(int, siginfo*, void*) () from /usr/java/jdk1.5.0_11/jre/lib/i386/server/libjvm.so #7 <signal handler called> #8 0x6b7209ec in writen () from /export/home/fengd/project/log/k/libhcnetsdk.so #9 0x6b76b9ab in TcpSendData (sock=1059, sBuffer=0x64f35258, nLength=44, nTimeOut=15000) at Tcpsock.cpp:698 #10 0x6b74ee1a in g_fCommandToDVR (lUserID=0, dwDVRIP=1446198331, wDVRPort=9000, lDVRUserID=0, dwLocalIP=3475186040, byMACAddr=0x6c5ba7a4 "", dwCommand=197123, lpInBuffer=0x6c5ba718, dwInBufferSize=12, lpOutBuffer=0x0, dwOutBufferSize=0, lpBytesReturned=0x0) at NetTrans.cpp:784 #11 0x6b728f16 in NET_DVR_PTZControlWithSpeed_Other (lUserID=0, lChannel=5, dwPTZCommand=23, dwStop=0, dwSpeed=3) at HCNetSDK.cpp:4579 #12 0x6bda8d5f in Java_cn_com_sbell_vss_csg_vsclient_hikvision_HcNetAdapter_controlPtzWithSpeed (env=0x8488de0, clsAdapter=0x6c5ba848, userId=0, channel=5, ptzCmd=23, isStop=0, speed=3) at cn_com_sbell_vss_csg_vsclient_hikvision_HcNetAdapter.cpp:326 DaFENG Coder Telecommunication && Network Industry Pudong Shanghai China