summaryrefslogtreecommitdiff
path: root/indra/cmake/Havok.cmake
diff options
context:
space:
mode:
authorNat Goodspeed <nat@lindenlab.com>2019-10-28 17:15:40 -0400
committerNat Goodspeed <nat@lindenlab.com>2020-03-25 19:05:17 -0400
commit07134aaee7a39f2141ee8f1e702aa0df989851df (patch)
tree86f7dbfc347881548e718a782c6567032041f46f /indra/cmake/Havok.cmake
parentf80b2da513b431b063c74a353d44ffc4a76fa24e (diff)
DRTVWR-476: Try to extend stderr redirection to Windows as well.
Make the LLError::Settings LLSingleton duplicate the file handle for stderr (usually 2) on construction. Make its destructor restore the original target for that file handle. Provide a getDupStderr() method to obtain the duplicate file handle. Move Settings declaration up to the top of the file so other code can reference it. Make RecordToFile (the Recorder subclass engaged by LLError::logToFile()), instead of duplicating stderr's file handle itself, capture the duplicate stderr file handle from Settings to revert stderr redirection on destruction. Make RecordToStderr (the Recorder subclass engaged by LLError::logToStderr()) use fdopen() to create an LLFILE* targeting the duplicate file handle from Settings. Write output to that instead of to stderr so logToStderr() continues to provide output for the user instead of duplicating each line into the log file.
Diffstat (limited to 'indra/cmake/Havok.cmake')
0 files changed, 0 insertions, 0 deletions