]> granicus.if.org Git - gc/commitdiff
Explicitly zero-initialize trace_buf
authorIvan Maidanski <ivmai@mail.ru>
Thu, 25 Apr 2019 07:04:02 +0000 (10:04 +0300)
committerIvan Maidanski <ivmai@mail.ru>
Thu, 25 Apr 2019 07:04:02 +0000 (10:04 +0300)
* mark.c [TRACE_BUF] (GC_trace_buf): Initialize to all zeros.

mark.c

diff --git a/mark.c b/mark.c
index 6aed170e601d9be798b328f61e6f1129001bf5d4..77d6b0b5051fa351d7020e45255c433369094e60 100644 (file)
--- a/mark.c
+++ b/mark.c
@@ -1512,7 +1512,7 @@ struct trace_entry {
     word bytes_allocd;
     word arg1;
     word arg2;
-} GC_trace_buf[TRACE_ENTRIES];
+} GC_trace_buf[TRACE_ENTRIES] = { { NULL, 0, 0, 0, 0 } };
 
 int GC_trace_buf_ptr = 0;