Your skill will accomplish what the force of many cannot |
|
PerlMonks |
Saving STDERR and displaying it laterby UnwashedCat (Acolyte) |
on Jul 03, 2006 at 18:01 UTC ( [id://559027]=perlquestion: print w/replies, xml ) | Need Help?? |
UnwashedCat has asked for the wisdom of the Perl Monks concerning the following question: I'm writing a program using the Curses::Application module. One issue I've been noticing is that when a die() occurs and a message is sent to STDERR, I never see it. I'm pretty sure the reason for this is that the message is displayed before my Curses::Application object is destroyed, which restores the terminal to normal line buffering mode. While in curses mode, STDOUT and STDERR don't seem to work properly. Right now I'm redirecting STDERR to a file, but that seems like a poor solution. Does anyone know of a way to 'store' messages to STDERR, and display them only AFTER the Curses::Application object is destroyed? Or maybe have a function that displays the error message in a dialog before closing down the program? Thanks!
Back to
Seekers of Perl Wisdom
|
|