jirentabu / crashrpt

Automatically exported from code.google.com/p/crashrpt
0 stars 0 forks source link

Memory allocation in CCrashHandler::GetExceptionPointers can fail #157

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?

After the program crashes CCrashHandler::GetExceptionPointers will use new to 
allocate memory for the EXCEPTION_RECORD and the EXCEPTION_POINTERS. If this 
fails it will call CCrashHandler::NewHandler which will again call 
GetExceptionPointers etc. After a while it will crash into __SEH_prolog and a 
crashdump will be generated.

I don't think NewHandler should be (indirectly) calling new...

What version of CrashRpt are you using?
1300
What is your version of Visual Studio?
2010 Professional
What is your version of Windows operating system?
Crash occured on Microsoft Windows XP Build 2600 Service Pack 3 (32 bit)

Original issue reported on code.google.com by gerardk...@gmail.com on 27 Jun 2012 at 9:05

GoogleCodeExporter commented 9 years ago
Maybe it should allocate some memory before crash, and reallocate it after 
crash only when the preallocated memory is not enough.

Original comment by zexspect...@gmail.com on 28 Jun 2012 at 2:35

GoogleCodeExporter commented 9 years ago
Now it allocates memory in stack instead of heap.

Original comment by zexspect...@gmail.com on 26 Aug 2012 at 5:47

GoogleCodeExporter commented 9 years ago
This issue was closed by revision r1353.

Original comment by zexspect...@gmail.com on 26 Aug 2012 at 5:48