Closed Bug 753856 Opened 9 years ago Closed 9 years ago
a CONERR$ file is created when firefox is launched from command line
Regression from bug 673383. Its patch assumes that a special file called `CONERR$` exists on Win32 and refer to some equivalent of `GetStdHandle( STD_ERROR_HANDLE )` but for the libc, when we are using freopen. According to the creation of this file, and to the following documentation, this magic file doesn't exists: http://msdn.microsoft.com/en-us/library/windows/desktop/ms683231%28v=vs.85%29.aspx
Here is a simple way to fix this, just use CONOUT$ instead. It sounds quite bad to mix stdout and stderr in the same pipe but I'm wondering if Windows command line supports any difference between both? I tried to build a more complex patch where I used same code than with -console . It looks like a better option as we have the feeling that we support stdout and stderr separately. It works fine on regular cmd.exe command line but fails when we launch firefox from cygwin. We don't get any std output.  http://mxr.mozilla.org/mozilla-central/source/toolkit/xre/nsNativeAppSupportWin.cpp#396
Assignee: nobody → poirot.alex
Oh and I fixed 80 column limit on comments and remove the `return;` statement as it prevents `-console` argument to work if we launch firefox from a command line. I don't see why we would use -console from a command line, but may be some tooling or old program want to do such thing!
FYI, here is the patch I mentioned in comment 1, which fails on cygwin.
Attachment #622795 - Flags: review?(ted.mielczarek)
Attachment #622795 - Flags: review?(ted.mielczarek) → review+
Here is try results: https://tbpl.mozilla.org/?tree=Try&rev=43f9478a5b20 Some failures, but seems to be intermittent ones?
Indeed, all known-intermittent.
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.