We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e4bc3f6 commit 94719ecCopy full SHA for 94719ec
src/memray/_memray/ghost_stack/src/ghost_stack.cpp
@@ -381,7 +381,7 @@ class GhostStackImpl {
381
// Copy to output buffer - return the IP of each frame (what unw_backtrace returns)
382
size_t count = (entries_.size() < max_frames) ? entries_.size() : max_frames;
383
for (size_t i = 0; i < count; ++i) {
384
- buffer[i] = reinterpret_cast<void*>(entries_[i].ip);
+ buffer[i] = reinterpret_cast<void*>(entries_[count - 1 - i].ip);
385
}
386
387
LOG_DEBUG("Captured %zu frames\n", count);
0 commit comments