Fix off-by-one.

This commit is contained in:
Bartosz Taudul 2018-06-20 17:02:05 +02:00
parent 7912807133
commit e495747b88

View File

@ -38,7 +38,7 @@ CallstackEntry DecodeCallstackPtr( uint64_t ptr );
static tracy_force_inline void* Callstack( int depth )
{
assert( depth >= 1 && depth <= 63 );
assert( depth >= 1 && depth < 63 );
auto trace = (uintptr_t*)tracy_malloc( ( 1 + depth ) * sizeof( uintptr_t ) );
const auto num = RtlCaptureStackBackTrace( 0, depth, (void**)( trace+1 ), nullptr );