Jump to content

I/O steam redirect failure. (Java, Bat/Au3)


Recommended Posts

Kinda mystified about a case where a application(Java in this case) generated some error message inside the console window (java.exe instead of javaw.exe). But when trying to redirect(bat) the message it a file, or capture it with au3, it seems to be gone. :blink:

The target error message is passed true the stdout stream. well assuming ... as it disappears from the bat console window when trying to redirect the stdout stream, while the error message still displays when only redirecting the stderr stream.

Anyone know a possible general reason for this odd behavior ?

Or ... is it something specific to Java and stdout. (As I could not find/test a (other) general Java message/output that was passed true stdout. (Java -version/-Help/, etc are all passed true stderr. And building my own Java_test_case.exe is not yet a available skill to me.)

[spelling]

Edited by MvGulik

"Straight_and_Crooked_Thinking" : A "classic guide to ferreting out untruths, half-truths, and other distortions of facts in political and social discussions."
"The Secrets of Quantum Physics" : New and excellent 2 part documentary on Quantum Physics by Jim Al-Khalili. (Dec 2014)

"Believing what you know ain't so" ...

Knock Knock ...
 

Link to comment
Share on other sites

Nope, The target error message is not send on the stderr stream. (+ redirection(bat) or capturing(au3) anything that is passed true the stderr stream works ok.)

while the error message still displays (in the console window) when only redirecting the stderr stream.

"Straight_and_Crooked_Thinking" : A "classic guide to ferreting out untruths, half-truths, and other distortions of facts in political and social discussions."
"The Secrets of Quantum Physics" : New and excellent 2 part documentary on Quantum Physics by Jim Al-Khalili. (Dec 2014)

"Believing what you know ain't so" ...

Knock Knock ...
 

Link to comment
Share on other sites

?

If you main, can I redirect the output you get when running "Java.exe -help", than yes I can. (this output is send over stderr btw, and not over stdout.).

? "C:Tempmyjava.exe": I'm running Jar files. CQ "java -jar MyJava.jar"

"Straight_and_Crooked_Thinking" : A "classic guide to ferreting out untruths, half-truths, and other distortions of facts in political and social discussions."
"The Secrets of Quantum Physics" : New and excellent 2 part documentary on Quantum Physics by Jim Al-Khalili. (Dec 2014)

"Believing what you know ain't so" ...

Knock Knock ...
 

Link to comment
Share on other sites

- Java sdk up.

- Running trough tutorials.

- Running "Java HelloWorldApp.class"

StdOut redirected just fine. So its seems not to be a general(as in normal) Java thing.

(But this is a class file, and not a Jar file. And ... I don't know yet if there is any significant difference between the two. ... more stuff to Read/ToDo ...)

"Straight_and_Crooked_Thinking" : A "classic guide to ferreting out untruths, half-truths, and other distortions of facts in political and social discussions."
"The Secrets of Quantum Physics" : New and excellent 2 part documentary on Quantum Physics by Jim Al-Khalili. (Dec 2014)

"Believing what you know ain't so" ...

Knock Knock ...
 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...