source: opengl-game/FileStackWalker.cpp@ d9b6a1c

feature/imgui-sdl points-test
Last change on this file since d9b6a1c was d9b6a1c, checked in by Dmitry Portnoy <dmitry.portnoy@…>, 5 years ago

Print a stack trace in the event of a crash. Currently, the code for this on Windows outputs the stack trace to stderr, not to a log file.

  • Property mode set to 100644
File size: 247 bytes
Line 
1#include "FileStackWalker.h"
2
3FileStackWalker::FileStackWalker(int fd_out) : StackWalker() {
4 this->fd_out = fd_out;
5}
6
7void FileStackWalker::OnOutput(LPCSTR szText) {
8 write(fd_out, szText, strlen(szText));
9 StackWalker::OnOutput(szText);
10}
Note: See TracBrowser for help on using the repository browser.