adplus

how can I run adplus in crash mode but not have it write a dump on shutdown?


If I run:

adplus.exe -pmn "MyClient.exe" -o "d:\DumpFiles" -crash

When I shut down I get a dump file created:

FULLDUMP_FirstChance_epr_Process_Shut_Down_MyClient.EXE__333c_2012-05-29_14-29-04-654_2690

Is there a way to run adplus in crash mode but not get this Process_Shut_Down dump created? (or does this mean there is an exception during shutdown?)

I want to monitor my application for run-time exceptions but don't want to fill up the hard drive if the program is exiting normally.


Solution

  • You can specify a configuration file when running adplus:

    This is the contents of my file: D:\DumpFiles\conf.txt

    <ADPlus Version='2'>
      <Exceptions>  
            <Exception Code="epr">
                <Actions1>Void</Actions1>
                <Actions2>Void</Actions2>
            </Exception> 
       </Exceptions>
    </ADPlus>
    

    Now we can run: adplus.exe -c D:\DumpFiles\conf.txt -pmn notepad++ -crash -o "D:\DumpFiles"

    Using the configuration file fixes this problem and adplus seems to be smart enough to just apply this “epr” exception rule as the only difference. I used WinMerge to compare the generated “DebuggerScript.txt” files.

    NOTE: if you taskkill notepad++ you won't get a dump if you are running with this configuration file.