c++filt causing flashing console windows

Ranjit Mathew rmathew@hotmail.com
Tue Sep 9 12:46:00 GMT 2003


Andrew Haley wrote:
> It says above that "the child process may nor may not create its own
> console/tty." Is it possible to build c++filt and addr2line in such a
> way that they do not try to create their own console/tty if the parent
> process doesn't have one? Or is this an unfixable Windows bug?

Rather than touching c++filt or addr2line, a simpler
fix would be to fix the call to CreateProcess( ) in
java/lang/natWin32Process.cc such that it asks Windows
to not create a console for the child process if it
itself is a GUI application.
IMHO, if the current process is a GUI application,
the spawned process (if it is a console application)
should be created with CREATE_NO_WINDOW set
in dwCreationFlags in the call to CreateProcess( ):
http://msdn.microsoft.com/library/en-us/dllproc/base/createprocess.asp
As noted the MSDN documentation (as well as the JDK
bug referenced earlier), this is not supported (ignored?)
on Win 95/98/ME. But that should be OK I guess.
The bit about determining whether the current process
is a GUI process and the to-be-spawned process is a
console process is left as an exercise for the reader.
:-)

Oyvind, I think we should file a libgcj bug in bugzilla
for this so that we do not lose track of this problem.
It might also help to put in a link to this thread
in the bug report.
Ranjit.
-- 
Ranjit Mathew Email: rmathew AT hotmail DOT com
Bangalore, INDIA. Web: http://ranjitmathew.tripod.com/


More information about the Java mailing list

AltStyle によって変換されたページ (->オリジナル) /