This commit is contained in:
Alex Crichton 2018-05-22 12:50:25 -07:00
parent e0abfecd2a
commit 6ccb800588
1 changed files with 3 additions and 1 deletions

View File

@ -604,7 +604,9 @@ coff_add (struct backtrace_state *state, int descriptor,
int str_view_valid;
uint32_t str_size;
off_t str_off;
struct backtrace_view syms_view;
// NOTE: upstream doesn't have `{0}`, this is a fix for Rust issue #39468.
// If syms_view is not initialized, then `free(syms_view.base)` may segfault later.
struct backtrace_view syms_view = {0};
off_t syms_off;
size_t syms_size;
int syms_view_valid;