You are here: C++ API > Classes > dtsFileConvertJob2 Structure > dtsFileConvertJob2::dtsCrashHandlerInfo Structure
dtSearch Text Retrieval Engine Programmer's Reference
dtsFileConvertJob2::dtsCrashHandlerInfo Structure

Used to install a crash handler so a stack trace can be recorded in the event of an unhandled exception

File: dtsearch.h

struct dtsCrashHandlerInfo { void * pData; void (* pNotifyFn)(void *pData, const char *logName); char appName[40]; char appVersion[40]; char logName[256]; const char * logName2; const char * miniDumpName; };
void * pData;
An optional value to be passed to the pNotifyFn.
void (* pNotifyFn)(void *pData, const char *logName);
An optional callback function to be called when a crash occurs.
char appName[40];
Information identifying the application, which will be written in the header of the log file.
char appVersion[40];
Information identifying the application, which will be written in the header of the log file.
char logName[256];
Deprecated: Use logName2
const char * logName2;
The name of the log file to create with the stack trace.
const char * miniDumpName;
Name of Windows MiniDump file to create

The functions to install and remove the crash handler are: void dtssInstallCrashDiagnostics(dtsCrashHandlerInfo& info) void dtssRemoveCrashDiagnostics() 

The stack trace file will list each item on the stack as an address. A utility included with the dtSearch Engine, StackTrace.exe, can be used to convert these addresses to symbol names. To use StackTrace.exe, you will need a .map file for your program. For example, if your program is MySearch.exe, you will need a map file named The Visual C++ linker does not generate map files by default so you will need to enable this option to get a map file. Also, the map file is only valid for the particular build for which it was generated. If you modify and rebuild the program, a new map file will be needed. Once you have a map file and the text file created by dtssInstallCrashDiagnostics, you can get the symbols as follows:

StackTrace Error.txt > ErrorWithSymbols.txt

If your program includes multiple modules, you can list the map files for each module before the error file, like this:

StackTrace Error.txt > ErrorWithSymbols.txt
Copyright (c) 1995-2021 dtSearch Corp. All rights reserved.