mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-17 21:38:11 +00:00
lib: Prevent unininted usage of data
Valgrind reports that some data being used in the stack unwind of a crash is being used uninitailized. Signed-off-by: Donald Sharp <sharpd@nvidia.com>
This commit is contained in:
parent
c882c9dd80
commit
63e040391d
@ -179,6 +179,9 @@ void zlog_backtrace_sigsafe(int priority, void *program_counter)
|
|||||||
unw_word_t ip, off, sp;
|
unw_word_t ip, off, sp;
|
||||||
Dl_info dlinfo;
|
Dl_info dlinfo;
|
||||||
|
|
||||||
|
memset(&uc, 0, sizeof(uc));
|
||||||
|
memset(&cursor, 0, sizeof(cursor));
|
||||||
|
|
||||||
unw_getcontext(&uc);
|
unw_getcontext(&uc);
|
||||||
unw_init_local(&cursor, &uc);
|
unw_init_local(&cursor, &uc);
|
||||||
while (unw_step(&cursor) > 0) {
|
while (unw_step(&cursor) > 0) {
|
||||||
|
Loading…
Reference in New Issue
Block a user