From 02609773c071675babc0c5aaa8eb2a1697befc44 Mon Sep 17 00:00:00 2001 From: Rusty Russell Date: Thu, 1 Aug 2019 11:04:05 +0930 Subject: [PATCH] lightningd: suppress gcc-7.4.0 error MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit In file included from wallet/test/run-wallet.c:15:0: ./lightningd/peer_htlcs.c: In function ‘htlcs_reconnect’: ./lightningd/peer_htlcs.c:2060:15: error: ‘failcode’ may be used uninitialized in this function [-Werror=maybe-uninitialized] } else if (failcode) { ^~~~~~~~ ./lightningd/peer_htlcs.c:2056:19: error: ‘failcode’ may be used uninitialized in this function [-Werror=maybe-uninitialized] failcode != 0 ~~~~~~~~~^~~~ Signed-off-by: Rusty Russell --- lightningd/peer_htlcs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lightningd/peer_htlcs.c b/lightningd/peer_htlcs.c index 7056568e6..c6da906fd 100644 --- a/lightningd/peer_htlcs.c +++ b/lightningd/peer_htlcs.c @@ -1990,7 +1990,7 @@ void htlcs_reconnect(struct lightningd *ld, struct htlc_in *hin; struct htlc_out *hout; struct htlc_in_map unprocessed; - enum onion_type failcode; + enum onion_type failcode COMPILER_WANTS_INIT("gcc7.4.0 bad, 8.3 OK"); /* Any HTLCs which happened to be incoming and weren't forwarded before * we shutdown/crashed: fail them now.