SymGetSearchPathW function (dbghelp.h)
Retrieves the symbol search path for the specified process.
Syntax
BOOL IMAGEAPI SymGetSearchPathW(
[in] HANDLE hProcess,
[out] PWSTR SearchPath,
[in] DWORD SearchPathLength
);
Parameters
[in] hProcess
A handle to the process that was originally passed to the SymInitialize function.
[out] SearchPath
A pointer to the buffer that receives the symbol search path.
[in] SearchPathLength
The size of the SearchPath buffer, in characters.
Return value
If the function succeeds, the return value is TRUE.
If the function fails, the return value is FALSE. To retrieve extended error information, call GetLastError.
Remarks
The SymGetSearchPath function copies the symbol search path for the specified process into the SearchPath buffer. If the function fails, the contents of the buffer are undefined.
To specify a symbol search path for the process, use the SymSetSearchPath function.
All DbgHelp functions, such as this one, are single threaded. Therefore, calls from more than one thread to this function will likely result in unexpected behavior or memory corruption. To avoid this, you must synchronize all concurrent calls from more than one thread to this function.
To call the Unicode version of this function, define DBGHELP_TRANSLATE_TCHAR.
Note
The dbghelp.h header defines SymGetSearchPath as an alias which automatically selects the ANSI or Unicode version of this function based on the definition of the UNICODE preprocessor constant. Mixing usage of the encoding-neutral alias with code that not encoding-neutral can lead to mismatches that result in compilation or runtime errors. For more information, see Conventions for Function Prototypes.
Requirements
Requirement | Value |
---|---|
Target Platform | Windows |
Header | dbghelp.h |
Library | Dbghelp.lib |
DLL | Dbghelp.dll |
Redistributable | DbgHelp.dll 5.1 or later |