pull out MakeCrashReport call

This commit is contained in:
Glenn Maynard
2006-02-11 07:52:39 +00:00
parent 9cbc530b64
commit bcab631922
@@ -452,7 +452,7 @@ static void MakeCrashReport( const CompleteCrashData &Data, RString &sOut )
sOut += ssprintf( "-- End of report\n" );
}
static void DoSave( const CompleteCrashData &Data )
static void DoSave( const RString &sReport )
{
RString sReport;
MakeCrashReport( Data, sReport );
@@ -611,10 +611,13 @@ void ChildProcess()
CompleteCrashData Data;
ReadCrashDataFromParent( fileno(stdin), Data );
RString sCrashReport;
VDDebugInfoInitFromFile( &g_debugInfo );
DoSave( Data );
MakeCrashReport( Data, sCrashReport );
VDDebugInfoDeinit( &g_debugInfo );
DoSave( Data );
/* Tell the crashing process that it can exit. Be sure to write crashinfo.txt first. */
int iCmd = 0;
write( _fileno(stdout), &iCmd, sizeof(iCmd) );