Closed Bug 901187 Opened 9 years ago Closed 9 years ago

Send printf_stderr output to OutputDebugString

Categories

(Core :: General, defect)

x86_64
Windows 8.1
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla26

People

(Reporter: kats, Assigned: kats)

References

Details

Attachments

(1 file, 1 obsolete file)

Attached patch Patch (obsolete) — Splinter Review
+++ This bug was initially created as a clone of Bug #762519 +++

Similar to the bug I'm cloning, I would like printf_stderr to go to the Visual Studio console output to make debugging on Metro easier.
Comment on attachment 785331 [details] [diff] [review]
Patch

Not sure who should review this, feel free to bounce it as needed.
Attachment #785331 - Attachment is patch: true
Attachment #785331 - Flags: review?(jmathies)
Attached patch PatchSplinter Review
Sorry, haven't gotten the right patch generation flags on this windows machine.
Assignee: nobody → bugmail.mozilla
Attachment #785331 - Attachment is obsolete: true
Attachment #785331 - Flags: review?(jmathies)
Attachment #785333 - Flags: review?(jmathies)
Comment on attachment 785333 [details] [diff] [review]
Patch

Looks ok but I can't r+ something in xpcom glue.
Attachment #785333 - Flags: review?(jmathies) → review?(benjamin)
Comment on attachment 785333 [details] [diff] [review]
Patch

Is there a particular reason why you early-return here, instead of printing to both stderr and OutputDebugStringA ?
Not particularly, no. I can let it fall through. I can also refactor the code to reduce duplication but that might result in the stderr version getting truncated at 2047 bytes as well, so maybe we don't want that.
Yeah, I'm not particularly worried about the truncation, but I'd like it to always print to stderr, because I personally at least often pipe output to a file even while I'm in a debugger session.
Comment on attachment 785333 [details] [diff] [review]
Patch

r=me with the return removed
Attachment #785333 - Flags: review?(benjamin) → review+
https://hg.mozilla.org/mozilla-central/rev/e4a05768e8c3
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla26
OS: Windows 8 Metro → Windows 8.1
You need to log in before you can comment on or make changes to this bug.