Forums before death by AOL, social media and spammers... "We can't have nice things"
|    comp.lang.c++.moderated    |    Moderated discussion of C++ superhackery    |    33,346 messages    |
[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]
|    Message 32,298 of 33,346    |
|    Martin B. to Mathias Gaunard    |
|    Re: Developing an exception hierarchy    |
|    16 May 12 10:37:50    |
      2e6ee723       From: 0xCDCDCDCD@gmx.at              On 15.05.2012 19:20, Mathias Gaunard wrote:       > On May 14, 2:18 am, "Martin B."<0xCDCDC...@gmx.at> wrote:       >       >> Agreed. We've switched to direct shutdown for lots of code. Some old       >> code where nothing ever was changed still uses the `catch(...)` approach       >> and it's really annoying analyzing the process dumps of exceptions where       >> the stack was unwound. (Windows: A proc dump is written with the exc       >> record of the thrown exception - but the stack of the origin is already       >> unwound.) Makes for some surreal post mortem debugging experiences in       >> WinDbg. :-)       >       > You should not catch exceptions when you want to debug them.       > A good way to deal with this is to add an option to run your unit       > tests or whole application in debug mode.       >              I wrote "post mortem" debugging. By this I meant "debugging" (if you can       call it that) the process/core dump the crashed application produced,       that is, viewing the crash dump in WinDbg. Since the exception record of       the "access violation" that caused the crash is set as active exception       record in the crash dump, the debugger will show the stack where the       exception was thrown ... except that it is already unwound and all local       objects show bogus (post d'tor) values.              cheers,       Martin              --       Good C++ code is better than good C code, but       bad C++ can be much, much worse than bad C code.                      [ See http://www.gotw.ca/resources/clcm.htm for info about ]        [ comp.lang.c++.moderated. First time posters: Do this! ]              --- SoupGate-Win32 v1.05        * Origin: you cannot sedate... all the things you hate (1:229/2)    |
[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]
(c) 1994, bbs@darkrealms.ca