mirror of
https://github.com/wolfpld/tracy.git
synced 2024-11-26 07:54:36 +00:00
Normalize symbol paths on libbacktrace systems.
This commit is contained in:
parent
8cc43284bd
commit
2cc5eff9a2
@ -894,7 +894,8 @@ static int SymbolAddressDataCb( void* data, uintptr_t pc, uintptr_t lowaddr, con
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
sym.file = CopyString( fn );
|
sym.file = NormalizePath( fn );
|
||||||
|
if( !sym.file ) sym.file = CopyString( fn );
|
||||||
sym.line = lineno;
|
sym.line = lineno;
|
||||||
sym.needFree = true;
|
sym.needFree = true;
|
||||||
}
|
}
|
||||||
@ -934,7 +935,8 @@ static int CodeDataCb( void* data, uintptr_t pc, uintptr_t lowaddr, const char*
|
|||||||
}
|
}
|
||||||
|
|
||||||
auto& sym = *(CallstackSymbolData*)data;
|
auto& sym = *(CallstackSymbolData*)data;
|
||||||
sym.file = CopyString( fn );
|
sym.file = NormalizePath( fn );
|
||||||
|
if( !sym.file ) sym.file = CopyString( fn );
|
||||||
sym.line = lineno;
|
sym.line = lineno;
|
||||||
sym.needFree = true;
|
sym.needFree = true;
|
||||||
sym.symAddr = lowaddr;
|
sym.symAddr = lowaddr;
|
||||||
@ -1009,7 +1011,8 @@ static int CallstackDataCb( void* /*data*/, uintptr_t pc, uintptr_t lowaddr, con
|
|||||||
|
|
||||||
const auto len = std::min<size_t>( strlen( function ), std::numeric_limits<uint16_t>::max() );
|
const auto len = std::min<size_t>( strlen( function ), std::numeric_limits<uint16_t>::max() );
|
||||||
cb_data[cb_num].name = CopyStringFast( function, len );
|
cb_data[cb_num].name = CopyStringFast( function, len );
|
||||||
cb_data[cb_num].file = CopyStringFast( fn );
|
cb_data[cb_num].file = NormalizePath( fn );
|
||||||
|
if( !cb_data[cb_num].file ) cb_data[cb_num].file = CopyStringFast( fn );
|
||||||
cb_data[cb_num].line = lineno;
|
cb_data[cb_num].line = lineno;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user