|
From: Betty G. <bet...@do...> - 2003-01-29 06:48:32
|
Dear all, I'm having some problems with log4cpp when my C++ codes is being used in JNI. I'm developing my codes in RH 7.2. The implementation of JNI is that I'm supposed to merge all my C++ codes into one .so shared library and JNI will load the library and then call the respective native methods. My codes works fine without JNI implementation, it runs well with logging and all. The problem starts when I build a shared library to be accessed by JNI. The compiling is okay, but when I try to run the JNI. JVM bombs. I tried tracing down the problem and found that the problem is due to the use of ostringstream in BasicLayout.cpp (which I'm currently using). I did a fix by changing the ostringstreams operations to sprintfs. But I still don't understand why ostringstream is causing the JVM errors. Could it be due to a memory leak or ?? It is not a good way to just change the ostringstream operations to sprintfs. Maybe there's something else need to be done to the ostringstream instances so that it won't cause these jvm errors? Can someone please enlighten me? Many thanks. regards, Betty -- _______________________________________________ Get your free email from www.doramail.com with 30 Megs of disk space in webhosting and e-mail storage! Powered by Outblaze |