How to redirect stdout/stderr from JVM launched in a C code
843829Aug 12 2005 — edited Aug 12 2005Hi all,
we have an hybrid application C++/Java. The JVM is launched from
C++ and then JNI is used in both direction from/to Java to/from C++.
The problem is that we suspect we have exceptions, not cautched
by our trace system (log4J). This can be for instance null pointer
exception that we cannot catch unless all methods are wrapped
into an expensive try/catch for all.
The question is: is it possible to redirect the stderr and stdout of
the JVM to a console or file so that we may have a chance to check
if we have an exception and where.
We are running under XP.
Thanks for all,
Xavier.