mirror of
https://git.FreeBSD.org/src.git
synced 2024-12-19 10:53:58 +00:00
When backtracing self, start with the current frame (i.e. the
frame of db_trace_self()) and not the caller's frame. The use of builtin_frame_address(1) to get the caller's frame is not reliable and can cause panics.
This commit is contained in:
parent
d4359345e6
commit
882561186b
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=203171
@ -206,6 +206,6 @@ db_trace_self(void)
|
|||||||
{
|
{
|
||||||
db_addr_t addr;
|
db_addr_t addr;
|
||||||
|
|
||||||
addr = (db_addr_t)__builtin_frame_address(1);
|
addr = (db_addr_t)__builtin_frame_address(0);
|
||||||
db_stack_trace_cmd(addr, -1);
|
db_stack_trace_cmd(addr, -1);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user