From: Martin Liska Date: Tue, 19 Nov 2019 07:22:21 +0000 (+0100) Subject: Initialize a variable due to -Wmaybe-uninitialized. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=e89a689f0a1b94083af100314373a6c2ef2c280e;p=gcc.git Initialize a variable due to -Wmaybe-uninitialized. 2019-11-19 Martin Liska PR bootstrap/92540 * config/riscv/riscv.c (riscv_address_insns): Initialize addr in order to remove boostrap -Wmaybe-uninitialized error. From-SVN: r278429 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 11414b23847..ab841a228cb 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,10 @@ +2019-11-19 Martin Liska + + PR bootstrap/92540 + * config/riscv/riscv.c (riscv_address_insns): Initialize + addr in order to remove boostrap -Wmaybe-uninitialized + error. + 2019-11-18 Martin Sebor PR tree-optimization/92493 diff --git a/gcc/config/riscv/riscv.c b/gcc/config/riscv/riscv.c index 11a43c1b64d..9aa4d266e6b 100644 --- a/gcc/config/riscv/riscv.c +++ b/gcc/config/riscv/riscv.c @@ -857,7 +857,7 @@ riscv_legitimate_address_p (machine_mode mode, rtx x, bool strict_p) int riscv_address_insns (rtx x, machine_mode mode, bool might_split_p) { - struct riscv_address_info addr; + struct riscv_address_info addr = {}; int n = 1; if (!riscv_classify_address (&addr, x, mode, false))