Skip to content

Commit 5ff84ae

Browse files
committed
lightningd: mangle parameter names in bitcoind_getrawblockbyheight_ so mocks don't get shadow warning.
When we make mocks (which the next patch will do), these names cause a warning: ``` wallet/test/run-db.c:32:64: error: declaration of ‘bitcoind’ shadows a parameter [-Werror=shadow=compatible-local] 32 | void (*cb)(struct bitcoind *bitcoind UNNEEDED, wallet/test/run-db.c:30:53: note: shadowed declaration is here 30 | struct bitcoind *bitcoind UNNEEDED, wallet/test/run-db.c:33:51: error: declaration of ‘height’ shadows a parameter [-Werror=shadow=compatible-local] 33 | u32 height UNNEEDED, wallet/test/run-db.c:31:40: note: shadowed declaration is here 31 | u32 height UNNEEDED, ``` Signed-off-by: Rusty Russell <[email protected]>
1 parent 52dfe9b commit 5ff84ae

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lightningd/bitcoind.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -127,8 +127,8 @@ void bitcoind_getchaininfo_(const tal_t *ctx,
127127
void bitcoind_getrawblockbyheight_(const tal_t *ctx,
128128
struct bitcoind *bitcoind,
129129
u32 height,
130-
void (*cb)(struct bitcoind *bitcoind,
131-
u32 height,
130+
void (*cb)(struct bitcoind *bitcoind_,
131+
u32 height_,
132132
struct bitcoin_blkid *blkid,
133133
struct bitcoin_block *blk,
134134
void *arg),

0 commit comments

Comments
 (0)