MCPcopy Create free account
hub / github.com/crownengine/crown / resolve

Method resolve

3rdparty/bx/src/debug.cpp:784–811  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

782 }
783
784 bool resolve(uintptr_t _addr, FixedString1024& _outFunctionName, FilePath& _outFilePath, int32_t& _outLine) const
785 {
786 if (hasSymbols() )
787 {
788 DbgHelpSymbolInfo dhsi = {};
789 dhsi.SizeOfStruct = sizeof(DbgHelpSymbolInfo) - sizeof(dhsi.Name);
790 dhsi.MaxNameLen = sizeof(dhsi.Name);
791
792 ImageHlpLine ihl = {};
793 ihl.SizeOfStruct = sizeof(ImageHlpLine);
794
795 uint32_t lineDisplacement;
796
797 if (true
798 && m_symFromAddr(kCurrentProcess, _addr, NULL, &dhsi)
799 && m_symGetLineFromAddr(kCurrentProcess, _addr, &lineDisplacement, &ihl)
800 )
801 {
802 _outFunctionName.set(dhsi.Name);
803 _outFilePath.set(ihl.FileName);
804 _outLine = ihl.LineNumber;
805
806 return true;
807 }
808 }
809
810 return false;
811 }
812
813 void cleanup()
814 {

Callers 1

writeCallstackFunction · 0.45

Calls 1

setMethod · 0.45

Tested by

no test coverage detected